Skip to content

Commit 29419b3

Browse files
Merge remote-tracking branch 'upstream/master' into bisect
2 parents 3a5aa51 + e989e31 commit 29419b3

File tree

107 files changed

+1794
-874
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

107 files changed

+1794
-874
lines changed

.pre-commit-config.yaml

+7-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
minimum_pre_commit_version: '2.9.2'
1+
minimum_pre_commit_version: 2.9.2
22
repos:
33
- repo: https://github.com/python/black
44
rev: 20.8b1
@@ -168,3 +168,9 @@ repos:
168168
exclude: ^LICENSES/|\.(html|csv|txt|svg|py)$
169169
- id: trailing-whitespace
170170
exclude: \.(html|svg)$
171+
- repo: https://github.com/codespell-project/codespell
172+
rev: v2.0.0
173+
hooks:
174+
- id: codespell
175+
types_or: [python, rst, markdown]
176+
files: ^pandas/core/

doc/source/development/contributing.rst

+11
Original file line numberDiff line numberDiff line change
@@ -1610,6 +1610,17 @@ request by pushing to the branch on GitHub::
16101610

16111611
git push origin shiny-new-feature
16121612

1613+
Autofixing formatting errors
1614+
----------------------------
1615+
1616+
We use several styling checks (e.g. ``black``, ``flake8``, ``isort``) which are run after
1617+
you make a pull request. If there is a scenario where any of these checks fail then you
1618+
can comment::
1619+
1620+
@github-actions pre-commit
1621+
1622+
on that pull request. This will trigger a workflow which will autofix formatting errors.
1623+
16131624
Delete your merged branch (optional)
16141625
------------------------------------
16151626

doc/source/development/maintaining.rst

+11
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,17 @@ Here are some things to check when reviewing a pull request.
151151
for regression fixes and small bug fixes, the next minor milestone otherwise)
152152
* Changes should comply with our :ref:`policies.version`.
153153

154+
Backporting
155+
-----------
156+
157+
In the case you want to apply changes to a stable branch from a newer branch then you
158+
can comment::
159+
160+
@meeseeksdev backport version-branch
161+
162+
This will trigger a workflow which will backport a given change to a branch
163+
(e.g. @meeseeksdev backport 1.2.x)
164+
154165
Cleaning up old issues
155166
----------------------
156167

doc/source/getting_started/intro_tutorials/02_read_write.rst

+4-29
Original file line numberDiff line numberDiff line change
@@ -16,38 +16,13 @@
1616
</div>
1717
<ul class="list-group list-group-flush">
1818
<li class="list-group-item">
19-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
20-
<span class="badge badge-dark">Titanic data</span>
21-
</div>
22-
<div class="collapse" id="collapsedata">
23-
<div class="card-body">
24-
<p class="card-text">
25-
26-
This tutorial uses the Titanic data set, stored as CSV. The data
27-
consists of the following data columns:
28-
29-
- PassengerId: Id of every passenger.
30-
- Survived: This feature have value 0 and 1. 0 for not survived and 1
31-
for survived.
32-
- Pclass: There are 3 classes: Class 1, Class 2 and Class 3.
33-
- Name: Name of passenger.
34-
- Sex: Gender of passenger.
35-
- Age: Age of passenger.
36-
- SibSp: Indication that passenger have siblings and spouse.
37-
- Parch: Whether a passenger is alone or have family.
38-
- Ticket: Ticket number of passenger.
39-
- Fare: Indicating the fare.
40-
- Cabin: The cabin of passenger.
41-
- Embarked: The embarked category.
19+
20+
.. include:: titanic.rst
4221

4322
.. raw:: html
4423

45-
</p>
46-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/titanic.csv" class="btn btn-dark btn-sm">To raw data</a>
47-
</div>
48-
</div>
49-
</li>
50-
</ul>
24+
</li>
25+
</ul>
5126
</div>
5227

5328
How do I read and write tabular data?

doc/source/getting_started/intro_tutorials/03_subset_data.rst

+3-31
Original file line numberDiff line numberDiff line change
@@ -16,36 +16,8 @@
1616
</div>
1717
<ul class="list-group list-group-flush">
1818
<li class="list-group-item">
19-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
20-
<span class="badge badge-dark">Titanic data</span>
21-
</div>
22-
<div class="collapse" id="collapsedata">
23-
<div class="card-body">
24-
<p class="card-text">
25-
26-
This tutorial uses the Titanic data set, stored as CSV. The data
27-
consists of the following data columns:
28-
29-
- PassengerId: Id of every passenger.
30-
- Survived: This feature has value 0 and 1. 0 for not survived and 1
31-
for survived.
32-
- Pclass: There are 3 classes: Class 1, Class 2 and Class 3.
33-
- Name: Name of passenger.
34-
- Sex: Gender of passenger.
35-
- Age: Age of passenger.
36-
- SibSp: Indication that passengers have siblings and spouses.
37-
- Parch: Whether a passenger is alone or has a family.
38-
- Ticket: Ticket number of passenger.
39-
- Fare: Indicating the fare.
40-
- Cabin: The cabin of passenger.
41-
- Embarked: The embarked category.
4219

43-
.. raw:: html
44-
45-
</p>
46-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/titanic.csv" class="btn btn-dark btn-sm">To raw data</a>
47-
</div>
48-
</div>
20+
.. include:: titanic.rst
4921

5022
.. ipython:: python
5123
@@ -54,8 +26,8 @@ consists of the following data columns:
5426
5527
.. raw:: html
5628

57-
</li>
58-
</ul>
29+
</li>
30+
</ul>
5931
</div>
6032

6133
How do I select a subset of a ``DataFrame``?

doc/source/getting_started/intro_tutorials/04_plotting.rst

+1-19
Original file line numberDiff line numberDiff line change
@@ -17,26 +17,8 @@
1717
</div>
1818
<ul class="list-group list-group-flush">
1919
<li class="list-group-item">
20-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
21-
<span class="badge badge-dark">Air quality data</span>
22-
</div>
23-
<div class="collapse" id="collapsedata">
24-
<div class="card-body">
25-
<p class="card-text">
2620

27-
For this tutorial, air quality data about :math:`NO_2` is used, made
28-
available by `openaq <https://openaq.org>`__ and using the
29-
`py-openaq <http://dhhagan.github.io/py-openaq/index.html>`__ package.
30-
The ``air_quality_no2.csv`` data set provides :math:`NO_2` values for
31-
the measurement stations *FR04014*, *BETR801* and *London Westminster*
32-
in respectively Paris, Antwerp and London.
33-
34-
.. raw:: html
35-
36-
</p>
37-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/air_quality_no2.csv" class="btn btn-dark btn-sm">To raw data</a>
38-
</div>
39-
</div>
21+
. include:: air_quality_no2.rst
4022

4123
.. ipython:: python
4224

doc/source/getting_started/intro_tutorials/05_add_columns.rst

+1-19
Original file line numberDiff line numberDiff line change
@@ -16,26 +16,8 @@
1616
</div>
1717
<ul class="list-group list-group-flush">
1818
<li class="list-group-item">
19-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
20-
<span class="badge badge-dark">Air quality data</span>
21-
</div>
22-
<div class="collapse" id="collapsedata">
23-
<div class="card-body">
24-
<p class="card-text">
25-
26-
For this tutorial, air quality data about :math:`NO_2` is used, made
27-
available by `openaq <https://openaq.org>`__ and using the
28-
`py-openaq <http://dhhagan.github.io/py-openaq/index.html>`__ package.
29-
The ``air_quality_no2.csv`` data set provides :math:`NO_2` values for
30-
the measurement stations *FR04014*, *BETR801* and *London Westminster*
31-
in respectively Paris, Antwerp and London.
3219

33-
.. raw:: html
34-
35-
</p>
36-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/air_quality_no2.csv" class="btn btn-dark btn-sm">To raw data</a>
37-
</div>
38-
</div>
20+
. include:: air_quality_no2.rst
3921

4022
.. ipython:: python
4123

doc/source/getting_started/intro_tutorials/06_calculate_statistics.rst

+3-31
Original file line numberDiff line numberDiff line change
@@ -16,36 +16,8 @@
1616
</div>
1717
<ul class="list-group list-group-flush">
1818
<li class="list-group-item">
19-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
20-
<span class="badge badge-dark">Titanic data</span>
21-
</div>
22-
<div class="collapse" id="collapsedata">
23-
<div class="card-body">
24-
<p class="card-text">
25-
26-
This tutorial uses the Titanic data set, stored as CSV. The data
27-
consists of the following data columns:
28-
29-
- PassengerId: Id of every passenger.
30-
- Survived: This feature have value 0 and 1. 0 for not survived and 1
31-
for survived.
32-
- Pclass: There are 3 classes: Class 1, Class 2 and Class 3.
33-
- Name: Name of passenger.
34-
- Sex: Gender of passenger.
35-
- Age: Age of passenger.
36-
- SibSp: Indication that passenger have siblings and spouse.
37-
- Parch: Whether a passenger is alone or have family.
38-
- Ticket: Ticket number of passenger.
39-
- Fare: Indicating the fare.
40-
- Cabin: The cabin of passenger.
41-
- Embarked: The embarked category.
4219

43-
.. raw:: html
44-
45-
</p>
46-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/titanic.csv" class="btn btn-dark btn-sm">To raw data</a>
47-
</div>
48-
</div>
20+
.. include:: titanic.rst
4921

5022
.. ipython:: python
5123
@@ -54,8 +26,8 @@ consists of the following data columns:
5426
5527
.. raw:: html
5628

57-
</li>
58-
</ul>
29+
</li>
30+
</ul>
5931
</div>
6032

6133
How to calculate summary statistics?

doc/source/getting_started/intro_tutorials/07_reshape_table_layout.rst

+3-31
Original file line numberDiff line numberDiff line change
@@ -16,36 +16,8 @@
1616
</div>
1717
<ul class="list-group list-group-flush">
1818
<li class="list-group-item">
19-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
20-
<span class="badge badge-dark">Titanic data</span>
21-
</div>
22-
<div class="collapse" id="collapsedata">
23-
<div class="card-body">
24-
<p class="card-text">
25-
26-
This tutorial uses the Titanic data set, stored as CSV. The data
27-
consists of the following data columns:
28-
29-
- PassengerId: Id of every passenger.
30-
- Survived: This feature have value 0 and 1. 0 for not survived and 1
31-
for survived.
32-
- Pclass: There are 3 classes: Class 1, Class 2 and Class 3.
33-
- Name: Name of passenger.
34-
- Sex: Gender of passenger.
35-
- Age: Age of passenger.
36-
- SibSp: Indication that passenger have siblings and spouse.
37-
- Parch: Whether a passenger is alone or have family.
38-
- Ticket: Ticket number of passenger.
39-
- Fare: Indicating the fare.
40-
- Cabin: The cabin of passenger.
41-
- Embarked: The embarked category.
4219

43-
.. raw:: html
44-
45-
</p>
46-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/titanic.csv" class="btn btn-dark btn-sm">To raw data</a>
47-
</div>
48-
</div>
20+
.. include:: titanic.rst
4921

5022
.. ipython:: python
5123
@@ -108,8 +80,8 @@ measurement.
10880
10981
.. raw:: html
11082

111-
</li>
112-
</ul>
83+
</li>
84+
</ul>
11385
</div>
11486

11587
How to reshape the layout of tables?

doc/source/getting_started/intro_tutorials/10_text_data.rst

+3-32
Original file line numberDiff line numberDiff line change
@@ -16,36 +16,7 @@
1616
</div>
1717
<ul class="list-group list-group-flush">
1818
<li class="list-group-item">
19-
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
20-
<span class="badge badge-dark">Titanic data</span>
21-
</div>
22-
<div class="collapse" id="collapsedata">
23-
<div class="card-body">
24-
<p class="card-text">
25-
26-
This tutorial uses the Titanic data set, stored as CSV. The data
27-
consists of the following data columns:
28-
29-
- PassengerId: Id of every passenger.
30-
- Survived: This feature have value 0 and 1. 0 for not survived and 1
31-
for survived.
32-
- Pclass: There are 3 classes: Class 1, Class 2 and Class 3.
33-
- Name: Name of passenger.
34-
- Sex: Gender of passenger.
35-
- Age: Age of passenger.
36-
- SibSp: Indication that passenger have siblings and spouse.
37-
- Parch: Whether a passenger is alone or have family.
38-
- Ticket: Ticket number of passenger.
39-
- Fare: Indicating the fare.
40-
- Cabin: The cabin of passenger.
41-
- Embarked: The embarked category.
42-
43-
.. raw:: html
44-
45-
</p>
46-
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/titanic.csv" class="btn btn-dark btn-sm">To raw data</a>
47-
</div>
48-
</div>
19+
.. include:: titanic.rst
4920

5021
.. ipython:: python
5122
@@ -54,8 +25,8 @@ consists of the following data columns:
5425
5526
.. raw:: html
5627

57-
</li>
58-
</ul>
28+
</li>
29+
</ul>
5930
</div>
6031

6132
How to manipulate textual data?
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
:orphan:
2+
3+
.. raw:: html
4+
5+
<div data-toggle="collapse" href="#collapsedata" role="button" aria-expanded="false" aria-controls="collapsedata">
6+
<span class="badge badge-dark">Air quality data</span>
7+
</div>
8+
<div class="collapse" id="collapsedata">
9+
<div class="card-body">
10+
<p class="card-text">
11+
12+
For this tutorial, air quality data about :math:`NO_2` is used, made
13+
available by `openaq <https://openaq.org>`__ and using the
14+
`py-openaq <http://dhhagan.github.io/py-openaq/index.html>`__ package.
15+
The ``air_quality_no2.csv`` data set provides :math:`NO_2` values for
16+
the measurement stations *FR04014*, *BETR801* and *London Westminster*
17+
in respectively Paris, Antwerp and London.
18+
19+
.. raw:: html
20+
21+
</p>
22+
<a href="https://github.com/pandas-dev/pandas/tree/master/doc/data/air_quality_no2.csv" class="btn btn-dark btn-sm">To raw data</a>
23+
</div>
24+
</div>

0 commit comments

Comments
 (0)