From c8e7a98d6e8ef88d2c397d524dcfdb302f6fb4c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dea=20Mar=C3=ADa=20L=C3=A9on?= Date: Fri, 29 Sep 2023 18:34:43 +0200 Subject: [PATCH] DOC: Removing repeated NA (#54821) * Remove repetead NA * Added file to toctree * changed _api.missing_value * Added NaT to missing values section --------- Co-authored-by: Marco Edward Gorelli --- doc/source/reference/arrays.rst | 13 ------------- doc/source/reference/index.rst | 1 + doc/source/reference/missing_value.rst | 24 ++++++++++++++++++++++++ 3 files changed, 25 insertions(+), 13 deletions(-) create mode 100644 doc/source/reference/missing_value.rst diff --git a/doc/source/reference/arrays.rst b/doc/source/reference/arrays.rst index 41ddbd048e6c5..fe65364896f54 100644 --- a/doc/source/reference/arrays.rst +++ b/doc/source/reference/arrays.rst @@ -134,11 +134,6 @@ is the missing value for datetime data. Timestamp -.. autosummary:: - :toctree: api/ - - NaT - Properties ~~~~~~~~~~ .. autosummary:: @@ -257,11 +252,6 @@ is the missing value for timedelta data. Timedelta -.. autosummary:: - :toctree: api/ - - NaT - Properties ~~~~~~~~~~ .. autosummary:: @@ -465,7 +455,6 @@ pandas provides this through :class:`arrays.IntegerArray`. UInt16Dtype UInt32Dtype UInt64Dtype - NA .. _api.arrays.float_na: @@ -484,7 +473,6 @@ Nullable float Float32Dtype Float64Dtype - NA .. _api.arrays.categorical: @@ -621,7 +609,6 @@ with a bool :class:`numpy.ndarray`. :template: autosummary/class_without_autosummary.rst BooleanDtype - NA .. Dtype attributes which are manually listed in their docstrings: including diff --git a/doc/source/reference/index.rst b/doc/source/reference/index.rst index 6d3ce3d31f005..7da02f7958416 100644 --- a/doc/source/reference/index.rst +++ b/doc/source/reference/index.rst @@ -53,6 +53,7 @@ are mentioned in the documentation. options extensions testing + missing_value .. This is to prevent warnings in the doc build. We don't want to encourage .. these methods. diff --git a/doc/source/reference/missing_value.rst b/doc/source/reference/missing_value.rst new file mode 100644 index 0000000000000..3bf22aef765d1 --- /dev/null +++ b/doc/source/reference/missing_value.rst @@ -0,0 +1,24 @@ +{{ header }} + +.. _api.missing_value: + +============== +Missing values +============== +.. currentmodule:: pandas + +NA is the way to represent missing values for nullable dtypes (see below): + +.. autosummary:: + :toctree: api/ + :template: autosummary/class_without_autosummary.rst + + NA + +NaT is the missing value for timedelta and datetime data (see below): + +.. autosummary:: + :toctree: api/ + :template: autosummary/class_without_autosummary.rst + + NaT