From 6ff05a588dbca5583b046d09e268a83938720445 Mon Sep 17 00:00:00 2001 From: wjm <3201884732@qq.com> Date: Fri, 11 Oct 2024 14:51:27 +0800 Subject: [PATCH 1/2] DOC: Fix title capitalization in documentation file --- doc/source/whatsnew/v0.12.0.rst | 12 ++++++------ doc/source/whatsnew/v0.25.0.rst | 2 +- doc/source/whatsnew/v1.2.0.rst | 2 +- doc/source/whatsnew/v3.0.0.rst | 8 ++++---- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/doc/source/whatsnew/v0.12.0.rst b/doc/source/whatsnew/v0.12.0.rst index c805758f85b35..08d3a6b188322 100644 --- a/doc/source/whatsnew/v0.12.0.rst +++ b/doc/source/whatsnew/v0.12.0.rst @@ -133,9 +133,9 @@ API changes to be inserted if ``True``, default is ``False`` (same as prior to 0.12) (:issue:`3679`) - Implement ``__nonzero__`` for ``NDFrame`` objects (:issue:`3691`, :issue:`3696`) - - IO api + - IO API - - added top-level function ``read_excel`` to replace the following, + - Added top-level function ``read_excel`` to replace the following, The original API is deprecated and will be removed in a future version .. code-block:: python @@ -153,7 +153,7 @@ API changes pd.read_excel("path_to_file.xls", "Sheet1", index_col=None, na_values=["NA"]) - - added top-level function ``read_sql`` that is equivalent to the following + - Added top-level function ``read_sql`` that is equivalent to the following .. code-block:: python @@ -482,11 +482,11 @@ Bug fixes - ``HDFStore`` - - will retain index attributes (freq,tz,name) on recreation (:issue:`3499`) - - will warn with a ``AttributeConflictWarning`` if you are attempting to append + - Will retain index attributes (freq,tz,name) on recreation (:issue:`3499`) + - Will warn with a ``AttributeConflictWarning`` if you are attempting to append an index with a different frequency than the existing, or attempting to append an index with a different name than the existing - - support datelike columns with a timezone as data_columns (:issue:`2852`) + - Support datelike columns with a timezone as data_columns (:issue:`2852`) - Non-unique index support clarified (:issue:`3468`). diff --git a/doc/source/whatsnew/v0.25.0.rst b/doc/source/whatsnew/v0.25.0.rst index bddb47cd3f629..453fa38ef8fc3 100644 --- a/doc/source/whatsnew/v0.25.0.rst +++ b/doc/source/whatsnew/v0.25.0.rst @@ -551,7 +551,7 @@ with :attr:`numpy.nan` in the case of an empty :class:`DataFrame` (:issue:`26397 ``__str__`` methods now call ``__repr__`` rather than vice versa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -pandas has until now mostly defined string representations in a pandas objects' +Pandas has until now mostly defined string representations in a pandas objects' ``__str__``/``__unicode__``/``__bytes__`` methods, and called ``__str__`` from the ``__repr__`` method, if a specific ``__repr__`` method is not found. This is not needed for Python3. In pandas 0.25, the string representations of pandas objects are now generally diff --git a/doc/source/whatsnew/v1.2.0.rst b/doc/source/whatsnew/v1.2.0.rst index 12ab4f27d1e62..fffcc39affccf 100644 --- a/doc/source/whatsnew/v1.2.0.rst +++ b/doc/source/whatsnew/v1.2.0.rst @@ -64,7 +64,7 @@ By default, duplicates continue to be allowed. label a [0, 1] -pandas will propagate the ``allows_duplicate_labels`` property through many operations. +Pandas will propagate the ``allows_duplicate_labels`` property through many operations. .. code-block:: ipython diff --git a/doc/source/whatsnew/v3.0.0.rst b/doc/source/whatsnew/v3.0.0.rst index 321005272817d..2603238436665 100644 --- a/doc/source/whatsnew/v3.0.0.rst +++ b/doc/source/whatsnew/v3.0.0.rst @@ -16,12 +16,12 @@ Enhancements .. _whatsnew_300.enhancements.enhancement1: -enhancement1 +Enhancement1 ^^^^^^^^^^^^ .. _whatsnew_300.enhancements.enhancement2: -enhancement2 +Enhancement2 ^^^^^^^^^^^^ .. _whatsnew_300.enhancements.other: @@ -269,7 +269,7 @@ This change also applies to :meth:`.DataFrameGroupBy.value_counts`. Here, there Increased minimum version for Python ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -pandas 3.0.0 supports Python 3.10 and higher. +Pandas 3.0.0 supports Python 3.10 and higher. Increased minimum versions for dependencies ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -305,7 +305,7 @@ See :ref:`install.dependencies` and :ref:`install.optional_dependencies` for mor ``pytz`` now an optional dependency ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -pandas now uses :py:mod:`zoneinfo` from the standard library as the default timezone implementation when passing a timezone +Pandas now uses :py:mod:`zoneinfo` from the standard library as the default timezone implementation when passing a timezone string to various methods. (:issue:`34916`) *Old behavior:* From 5935a5380d62bcd63ec52196721ee542fc7c8c7b Mon Sep 17 00:00:00 2001 From: wjm <3201884732@qq.com> Date: Sat, 12 Oct 2024 08:16:03 +0800 Subject: [PATCH 2/2] DOC: Fix title capitalization in documentation files --- doc/source/whatsnew/v0.25.0.rst | 2 +- doc/source/whatsnew/v1.2.0.rst | 2 +- doc/source/whatsnew/v3.0.0.rst | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/source/whatsnew/v0.25.0.rst b/doc/source/whatsnew/v0.25.0.rst index 453fa38ef8fc3..bddb47cd3f629 100644 --- a/doc/source/whatsnew/v0.25.0.rst +++ b/doc/source/whatsnew/v0.25.0.rst @@ -551,7 +551,7 @@ with :attr:`numpy.nan` in the case of an empty :class:`DataFrame` (:issue:`26397 ``__str__`` methods now call ``__repr__`` rather than vice versa ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Pandas has until now mostly defined string representations in a pandas objects' +pandas has until now mostly defined string representations in a pandas objects' ``__str__``/``__unicode__``/``__bytes__`` methods, and called ``__str__`` from the ``__repr__`` method, if a specific ``__repr__`` method is not found. This is not needed for Python3. In pandas 0.25, the string representations of pandas objects are now generally diff --git a/doc/source/whatsnew/v1.2.0.rst b/doc/source/whatsnew/v1.2.0.rst index fffcc39affccf..12ab4f27d1e62 100644 --- a/doc/source/whatsnew/v1.2.0.rst +++ b/doc/source/whatsnew/v1.2.0.rst @@ -64,7 +64,7 @@ By default, duplicates continue to be allowed. label a [0, 1] -Pandas will propagate the ``allows_duplicate_labels`` property through many operations. +pandas will propagate the ``allows_duplicate_labels`` property through many operations. .. code-block:: ipython diff --git a/doc/source/whatsnew/v3.0.0.rst b/doc/source/whatsnew/v3.0.0.rst index 2603238436665..e5376177d3381 100644 --- a/doc/source/whatsnew/v3.0.0.rst +++ b/doc/source/whatsnew/v3.0.0.rst @@ -269,7 +269,7 @@ This change also applies to :meth:`.DataFrameGroupBy.value_counts`. Here, there Increased minimum version for Python ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Pandas 3.0.0 supports Python 3.10 and higher. +pandas 3.0.0 supports Python 3.10 and higher. Increased minimum versions for dependencies ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -305,7 +305,7 @@ See :ref:`install.dependencies` and :ref:`install.optional_dependencies` for mor ``pytz`` now an optional dependency ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Pandas now uses :py:mod:`zoneinfo` from the standard library as the default timezone implementation when passing a timezone +pandas now uses :py:mod:`zoneinfo` from the standard library as the default timezone implementation when passing a timezone string to various methods. (:issue:`34916`) *Old behavior:*