From 7e375a55e3ce4bc8881dccfb4a9281cf85b93ea6 Mon Sep 17 00:00:00 2001 From: tuhinsharma121 Date: Tue, 7 May 2024 17:10:56 +0530 Subject: [PATCH 1/2] DOC: add PR01,SA01 for pandas.api.indexers.BaseIndexer --- pandas/core/indexers/objects.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/pandas/core/indexers/objects.py b/pandas/core/indexers/objects.py index d108f840a1b4f..5912f78c95c73 100644 --- a/pandas/core/indexers/objects.py +++ b/pandas/core/indexers/objects.py @@ -48,6 +48,25 @@ class BaseIndexer: """ Base class for window bounds calculations. + Parameters + ---------- + index_array : np.ndarray, default None + Array-like structure representing the indices for the data points. + If None, the default indices are assumed. This can be useful for + handling non-uniform indices in data, such as in time series + with irregular timestamps. + window_size : int, default 0 + Size of the moving window. This is the number of observations used + for calculating the statistic. The default is to consider all + observations within the window. + **kwargs + Additional keyword arguments passed to the subclass's methods. + + See Also + -------- + DataFrame.rolling : Provides rolling window calculations on dataframe. + Series.rolling : Provides rolling window calculations on series. + Examples -------- >>> from pandas.api.indexers import BaseIndexer From 6bfaa0d7f15332ceabec2c7fd551be2ebf983c57 Mon Sep 17 00:00:00 2001 From: tuhinsharma121 Date: Tue, 7 May 2024 17:11:19 +0530 Subject: [PATCH 2/2] DOC: remove PR01,SA01 for pandas.api.indexers.BaseIndexer --- ci/code_checks.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/ci/code_checks.sh b/ci/code_checks.sh index 83d9ef3d05dba..fe26b7506108f 100755 --- a/ci/code_checks.sh +++ b/ci/code_checks.sh @@ -371,7 +371,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then -i "pandas.api.extensions.ExtensionArray.unique RT03,SA01" \ -i "pandas.api.extensions.ExtensionArray.view SA01" \ -i "pandas.api.extensions.register_extension_dtype SA01" \ - -i "pandas.api.indexers.BaseIndexer PR01,SA01" \ -i "pandas.api.indexers.FixedForwardWindowIndexer PR01,SA01" \ -i "pandas.api.indexers.VariableOffsetWindowIndexer PR01,SA01" \ -i "pandas.api.interchange.from_dataframe RT03,SA01" \