You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#. Include the full version string of *pandas* and its dependencies. You can use the built-in function::
78
+
#. Include the full version string of pandas and its dependencies. You can use the built-in function::
79
79
80
80
>>> import pandas as pd
81
81
>>> pd.show_versions()
82
82
83
83
#. Explain why the current behavior is wrong/not desired and what you expect instead.
84
84
85
-
The issue will then show up to the *pandas* community and be open to comments/ideas from others.
85
+
The issue will then show up to the pandas community and be open to comments/ideas from others.
86
86
87
87
.. _contributing.github:
88
88
89
89
Working with the code
90
90
=====================
91
91
92
92
Now that you have an issue you want to fix, enhancement to add, or documentation to improve,
93
-
you need to learn how to work with GitHub and the *pandas* code base.
93
+
you need to learn how to work with GitHub and the pandas code base.
94
94
95
95
.. _contributing.version_control:
96
96
97
97
Version control, Git, and GitHub
98
98
--------------------------------
99
99
100
-
To the new user, working with Git is one of the more daunting aspects of contributing to *pandas*.
100
+
To the new user, working with Git is one of the more daunting aspects of contributing to pandas.
101
101
It can very quickly become overwhelming, but sticking to the guidelines below will help keep the process
102
102
straightforward and mostly trouble free. As always, if you are having difficulties please
103
103
feel free to ask for help.
@@ -221,7 +221,7 @@ environment:
221
221
<https://conda.io/miniconda.html>`_
222
222
* Make sure your conda is up to date (``conda update conda``)
223
223
* Make sure that you have :ref:`cloned the repository <contributing.forking>`
224
-
* ``cd`` to the *pandas* source directory
224
+
* ``cd`` to the pandas source directory
225
225
226
226
We'll now kick off a three-step process:
227
227
@@ -330,7 +330,7 @@ The above can be simplified to::
330
330
331
331
This changes your working directory to the shiny-new-feature branch. Keep any
332
332
changes in this branch specific to one bug or feature so it is clear
333
-
what the branch brings to *pandas*. You can have many shiny-new-features
333
+
what the branch brings to pandas. You can have many shiny-new-features
334
334
and switch in between them using the git checkout command.
335
335
336
336
When creating this branch, make sure your master branch is up to date with
@@ -349,9 +349,9 @@ you created the branch, check the section on
349
349
Contributing to the documentation
350
350
=================================
351
351
352
-
Contributing to the documentation benefits everyone who uses *pandas*.
352
+
Contributing to the documentation benefits everyone who uses pandas.
353
353
We encourage you to help us improve the documentation, and
354
-
you don't have to be an expert on *pandas* to do so! In fact,
354
+
you don't have to be an expert on pandas to do so! In fact,
355
355
there are sections of the docs that are worse off after being written by
356
356
experts. If something in the docs doesn't make sense to you, updating the
357
357
relevant section after you figure it out is a great way to ensure it will help
@@ -361,7 +361,7 @@ the next person.
361
361
:local:
362
362
363
363
364
-
About the *pandas* documentation
364
+
About the pandas documentation
365
365
--------------------------------
366
366
367
367
The documentation is written in **reStructuredText**, which is almost like writing
@@ -372,7 +372,7 @@ complex changes to the documentation as well.
372
372
373
373
Some other important things to know about the docs:
374
374
375
-
* The *pandas* documentation consists of two parts: the docstrings in the code
375
+
* The pandas documentation consists of two parts: the docstrings in the code
376
376
itself and the docs in this folder ``doc/``.
377
377
378
378
The docstrings provide a clear explanation of the usage of the individual
@@ -452,7 +452,7 @@ This will identify methods documented in ``doc/source/reference`` that are not a
452
452
class methods, and existing methods that are not documented in ``doc/source/reference``.
453
453
454
454
455
-
Updating a *pandas* docstring
455
+
Updating a pandas docstring
456
456
-----------------------------
457
457
458
458
When improving a single function or method's docstring, it is not necessarily
@@ -477,7 +477,7 @@ When doing a PR with a docstring update, it is good to post the
477
477
output of the validation script in a comment on github.
478
478
479
479
480
-
How to build the *pandas* documentation
480
+
How to build the pandas documentation
481
481
---------------------------------------
482
482
483
483
Requirements
@@ -543,7 +543,7 @@ And you'll have the satisfaction of seeing your new and improved documentation!
543
543
Building master branch documentation
544
544
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
545
545
546
-
When pull requests are merged into the *pandas* ``master`` branch, the main parts of
546
+
When pull requests are merged into the pandas ``master`` branch, the main parts of
547
547
the documentation are also built by Travis-CI. These docs are then hosted `here
548
548
<https://dev.pandas.io>`__, see also
549
549
the :ref:`Continuous Integration <contributing.ci>` section.
@@ -563,7 +563,7 @@ Writing good code is not just about what you write. It is also about *how* you
563
563
write it. During :ref:`Continuous Integration <contributing.ci>` testing, several
564
564
tools will be run to check your code for stylistic errors.
565
565
Generating any warnings will cause the test to fail.
566
-
Thus, good style is a requirement for submitting code to *pandas*.
566
+
Thus, good style is a requirement for submitting code to pandas.
567
567
568
568
There is a tool in pandas to help contributors verify their changes before
569
569
contributing them to the project::
@@ -601,7 +601,7 @@ set in the ``pandas.compat._optional.VERSIONS`` dict.
601
601
C (cpplint)
602
602
~~~~~~~~~~~
603
603
604
-
*pandas* uses the `Google <https://google.github.io/styleguide/cppguide.html>`_
604
+
pandas uses the `Google <https://google.github.io/styleguide/cppguide.html>`_
605
605
standard. Google provides an open source style checker called ``cpplint``, but we
606
606
use a fork of it that can be found `here <https://github.com/cpplint/cpplint>`__.
607
607
Here are *some* of the more common ``cpplint`` issues:
@@ -652,7 +652,7 @@ fixes manually.
652
652
Python (PEP8 / black)
653
653
~~~~~~~~~~~~~~~~~~~~~
654
654
655
-
*pandas* follows the `PEP8 <https://www.python.org/dev/peps/pep-0008/>`_ standard
655
+
pandas follows the `PEP8 <https://www.python.org/dev/peps/pep-0008/>`_ standard
656
656
and uses `Black <https://black.readthedocs.io/en/stable/>`_ and
657
657
`Flake8 <http://flake8.pycqa.org/en/latest/>`_ to ensure a consistent code
658
658
format throughout the project.
@@ -703,7 +703,7 @@ Note that these commands can be run analogously with ``black``.
703
703
704
704
Import formatting
705
705
~~~~~~~~~~~~~~~~~
706
-
*pandas* uses `isort <https://pypi.org/project/isort/>`__ to standardise import
706
+
pandas uses `isort <https://pypi.org/project/isort/>`__ to standardise import
707
707
formatting across the codebase.
708
708
709
709
A guide to import layout as per pep8 can be found `here <https://www.python.org/dev/peps/pep-0008/#imports/>`__.
@@ -778,7 +778,7 @@ Note that if needed, you can skip these checks with ``git commit --no-verify``.
778
778
Backwards compatibility
779
779
~~~~~~~~~~~~~~~~~~~~~~~
780
780
781
-
Please try to maintain backward compatibility. *pandas* has lots of users with lots of
781
+
Please try to maintain backward compatibility. pandas has lots of users with lots of
782
782
existing code, so don't break it if at all possible. If you think breakage is required,
783
783
clearly state why as part of the pull request. Also, be careful when changing method
784
784
signatures and add deprecation warnings where needed. Also, add the deprecated sphinx
@@ -825,7 +825,7 @@ See :ref:`contributing.warnings` for more.
825
825
Type hints
826
826
----------
827
827
828
-
*pandas* strongly encourages the use of :pep:`484` style type hints. New development should contain type hints and pull requests to annotate existing code are accepted as well!
828
+
pandas strongly encourages the use of :pep:`484` style type hints. New development should contain type hints and pull requests to annotate existing code are accepted as well!
829
829
830
830
Style guidelines
831
831
~~~~~~~~~~~~~~~~
@@ -906,9 +906,9 @@ With custom types and inference this is not always possible so exceptions are ma
906
906
pandas-specific types
907
907
~~~~~~~~~~~~~~~~~~~~~
908
908
909
-
Commonly used types specific to *pandas* will appear in `pandas._typing <https://github.com/pandas-dev/pandas/blob/master/pandas/_typing.py>`_ and you should use these where applicable. This module is private for now but ultimately this should be exposed to third party libraries who want to implement type checking against pandas.
909
+
Commonly used types specific to pandas will appear in `pandas._typing <https://github.com/pandas-dev/pandas/blob/master/pandas/_typing.py>`_ and you should use these where applicable. This module is private for now but ultimately this should be exposed to third party libraries who want to implement type checking against pandas.
910
910
911
-
For example, quite a few functions in *pandas* accept a ``dtype`` argument. This can be expressed as a string like ``"object"``, a ``numpy.dtype`` like ``np.int64`` or even a pandas ``ExtensionDtype`` like ``pd.CategoricalDtype``. Rather than burden the user with having to constantly annotate all of those options, this can simply be imported and reused from the pandas._typing module
911
+
For example, quite a few functions in pandas accept a ``dtype`` argument. This can be expressed as a string like ``"object"``, a ``numpy.dtype`` like ``np.int64`` or even a pandas ``ExtensionDtype`` like ``pd.CategoricalDtype``. Rather than burden the user with having to constantly annotate all of those options, this can simply be imported and reused from the pandas._typing module
912
912
913
913
.. code-block:: python
914
914
@@ -922,7 +922,7 @@ This module will ultimately house types for repeatedly used concepts like "path-
922
922
Validating type hints
923
923
~~~~~~~~~~~~~~~~~~~~~
924
924
925
-
*pandas* uses `mypy <http://mypy-lang.org>`_ to statically analyze the code base and type hints. After making any change you can ensure your type hints are correct by running
925
+
pandas uses `mypy <http://mypy-lang.org>`_ to statically analyze the code base and type hints. After making any change you can ensure your type hints are correct by running
926
926
927
927
.. code-block:: shell
928
928
@@ -933,7 +933,7 @@ Validating type hints
933
933
Testing with continuous integration
934
934
-----------------------------------
935
935
936
-
The *pandas* test suite will run automatically on `Travis-CI <https://travis-ci.org/>`__ and
936
+
The pandas test suite will run automatically on `Travis-CI <https://travis-ci.org/>`__ and
0 commit comments