Skip to content

Commit

Permalink
Merge branch 'master' into parquet-categorical
Browse files Browse the repository at this point in the history
* master: (40 commits)
  DOC: Fix GL01 and GL02 errors in the docstrings (pandas-dev#27988)
  Remove Encoding of values in char** For Labels (pandas-dev#27618)
  TYPING: more type hints for io.formats.printing (pandas-dev#27765)
  TST: fix compression tests when run without virtualenv/condaenv (pandas-dev#28051)
  DOC: Start 0.25.2 (pandas-dev#28111)
  DOC: Fix docstrings lack of punctuation (pandas-dev#28031)
  DOC: Remove alias for numpy.random.randn from the docs (pandas-dev#28082)
  DOC: update GroupBy.head()/tail() documentation (pandas-dev#27844)
  BUG: timedelta merge asof with tolerance (pandas-dev#27650)
  BUG: Series.rename raises error on values accepted by Series construc… (pandas-dev#27814)
  Preserve index when setting new column on empty dataframe. (pandas-dev#26471)
  BUG: Fixed groupby quantile for listlike q (pandas-dev#27827)
  BUG: iter with readonly values, closes pandas-dev#28055 (pandas-dev#28074)
  TST: non-strict xfail for period test (pandas-dev#28072)
  DOC: Update whatsnew (pandas-dev#28073)
  CI: disable codecov (pandas-dev#28065)
  CI: Set SHA for codecov upload (pandas-dev#28067)
  BUG: Correct the previous bug fixing on xlim for plotting (pandas-dev#28059)
  CI: Add pip dependence explicitly (pandas-dev#28008)
  DOC: Change document code prun in a row (pandas-dev#28029)
  ...
  • Loading branch information
galuhsahid committed Aug 25, 2019
2 parents aebfae7 + 5c0da7d commit 1e3df80
Show file tree
Hide file tree
Showing 70 changed files with 1,128 additions and 466 deletions.
1 change: 1 addition & 0 deletions ci/deps/azure-macos-35.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ dependencies:
- xlrd
- xlsxwriter
- xlwt
- pip
- pip:
- pyreadstat
# universal
Expand Down
11 changes: 6 additions & 5 deletions ci/run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,10 @@ do
# if no tests are found (the case of "single and slow"), pytest exits with code 5, and would make the script fail, if not for the below code
sh -c "$PYTEST_CMD; ret=\$?; [ \$ret = 5 ] && exit 0 || exit \$ret"

if [[ "$COVERAGE" && $? == 0 ]]; then
echo "uploading coverage for $TYPE tests"
echo "bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME"
bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME
fi
# 2019-08-21 disabling because this is hitting HTTP 400 errors GH#27602
# if [[ "$COVERAGE" && $? == 0 && "$TRAVIS_BRANCH" == "master" ]]; then
# echo "uploading coverage for $TYPE tests"
# echo "bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME"
# bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME
# fi
done
1 change: 0 additions & 1 deletion doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,6 @@
import numpy as np
import pandas as pd
randn = np.random.randn
np.random.seed(123456)
np.set_printoptions(precision=4, suppress=True)
pd.options.display.max_rows = 15
Expand Down
6 changes: 3 additions & 3 deletions doc/source/user_guide/enhancingperf.rst
Original file line number Diff line number Diff line change
Expand Up @@ -243,9 +243,9 @@ We've gotten another big improvement. Let's check again where the time is spent:

.. ipython:: python
%prun -l 4 apply_integrate_f(df['a'].to_numpy(),
df['b'].to_numpy(),
df['N'].to_numpy())
%%prun -l 4 apply_integrate_f(df['a'].to_numpy(),
df['b'].to_numpy(),
df['N'].to_numpy())
As one might expect, the majority of the time is now spent in ``apply_integrate_f``,
so if we wanted to make anymore efficiencies we must continue to concentrate our
Expand Down
2 changes: 2 additions & 0 deletions doc/source/user_guide/io.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ The pandas I/O API is a set of top level ``reader`` functions accessed like
:delim: ;

text;`CSV <https://en.wikipedia.org/wiki/Comma-separated_values>`__;:ref:`read_csv<io.read_csv_table>`;:ref:`to_csv<io.store_in_csv>`
text;Fixed-Width Text File;:ref:`read_fwf<io.fwf_reader>`
text;`JSON <https://www.json.org/>`__;:ref:`read_json<io.json_reader>`;:ref:`to_json<io.json_writer>`
text;`HTML <https://en.wikipedia.org/wiki/HTML>`__;:ref:`read_html<io.read_html>`;:ref:`to_html<io.html>`
text; Local clipboard;:ref:`read_clipboard<io.clipboard>`;:ref:`to_clipboard<io.clipboard>`
Expand Down Expand Up @@ -1372,6 +1373,7 @@ should pass the ``escapechar`` option:
print(data)
pd.read_csv(StringIO(data), escapechar='\\')
.. _io.fwf_reader:
.. _io.fwf:

Files with fixed width columns
Expand Down
1 change: 1 addition & 0 deletions doc/source/whatsnew/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ Version 0.25
.. toctree::
:maxdepth: 2

v0.25.2
v0.25.1
v0.25.0

Expand Down
2 changes: 1 addition & 1 deletion doc/source/whatsnew/v0.10.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@ Here is a taste of what to expect.

.. code-block:: ipython
In [58]: p4d = Panel4D(randn(2, 2, 5, 4),
In [58]: p4d = Panel4D(np.random.randn(2, 2, 5, 4),
....: labels=['Label1','Label2'],
....: items=['Item1', 'Item2'],
....: major_axis=date_range('1/1/2000', periods=5),
Expand Down
108 changes: 30 additions & 78 deletions doc/source/whatsnew/v0.25.1.rst
Original file line number Diff line number Diff line change
@@ -1,163 +1,115 @@
.. _whatsnew_0251:

What's new in 0.25.1 (July XX, 2019)
------------------------------------

Enhancements
~~~~~~~~~~~~
What's new in 0.25.1 (August 21, 2019)
--------------------------------------

These are the changes in pandas 0.25.1. See :ref:`release` for a full changelog
including other versions of pandas.

.. _whatsnew_0251.enhancements.other:

Other enhancements
^^^^^^^^^^^^^^^^^^
I/O and LZMA
~~~~~~~~~~~~

-
-
-
Some users may unknowingly have an incomplete Python installation lacking the `lzma` module from the standard library. In this case, `import pandas` failed due to an `ImportError` (:issue: `27575`).
Pandas will now warn, rather than raising an `ImportError` if the `lzma` module is not present. Any subsequent attempt to use `lzma` methods will raise a `RuntimeError`.
A possible fix for the lack of the `lzma` module is to ensure you have the necessary libraries and then re-install Python.
For example, on MacOS installing Python with `pyenv` may lead to an incomplete Python installation due to unmet system dependencies at compilation time (like `xz`). Compilation will succeed, but Python might fail at run time. The issue can be solved by installing the necessary dependencies and then re-installing Python.

.. _whatsnew_0251.bug_fixes:

Bug fixes
~~~~~~~~~


Categorical
^^^^^^^^^^^

- Bug in :meth:`Categorical.fillna` would replace all values, not just those that are ``NaN`` (:issue:`26215`)
-
- Bug in :meth:`Categorical.fillna` that would replace all values, not just those that are ``NaN`` (:issue:`26215`)

Datetimelike
^^^^^^^^^^^^
- Bug in :func:`to_datetime` where passing a timezone-naive :class:`DatetimeArray` or :class:`DatetimeIndex` and ``utc=True`` would incorrectly return a timezone-naive result (:issue:`27733`)
-
-
-

Timedelta
^^^^^^^^^

-
-
-
- Bug in :func:`to_datetime` where passing a timezone-naive :class:`DatetimeArray` or :class:`DatetimeIndex` and ``utc=True`` would incorrectly return a timezone-naive result (:issue:`27733`)
- Bug in :meth:`Period.to_timestamp` where a :class:`Period` outside the :class:`Timestamp` implementation bounds (roughly 1677-09-21 to 2262-04-11) would return an incorrect :class:`Timestamp` instead of raising ``OutOfBoundsDatetime`` (:issue:`19643`)
- Bug in iterating over :class:`DatetimeIndex` when the underlying data is read-only (:issue:`28055`)

Timezones
^^^^^^^^^

- Bug in :class:`Index` where a numpy object array with a timezone aware :class:`Timestamp` and ``np.nan`` would not return a :class:`DatetimeIndex` (:issue:`27011`)
-
-

Numeric
^^^^^^^

- Bug in :meth:`Series.interpolate` when using a timezone aware :class:`DatetimeIndex` (:issue:`27548`)
- Bug when printing negative floating point complex numbers would raise an ``IndexError`` (:issue:`27484`)
-
-
- Bug where :class:`DataFrame` arithmetic operators such as :meth:`DataFrame.mul` with a :class:`Series` with axis=1 would raise an ``AttributeError`` on :class:`DataFrame` larger than the minimum threshold to invoke numexpr (:issue:`27636`)
- Bug in :class:`DataFrame` arithmetic where missing values in results were incorrectly masked with ``NaN`` instead of ``Inf`` (:issue:`27464`)

Conversion
^^^^^^^^^^

- Improved the warnings for the deprecated methods :meth:`Series.real` and :meth:`Series.imag` (:issue:`27610`)
-
-

Strings
^^^^^^^

-
-
-


Interval
^^^^^^^^

- Bug in :class:`IntervalIndex` where `dir(obj)` would raise ``ValueError`` (:issue:`27571`)
-
-
-

Indexing
^^^^^^^^

- Bug in partial-string indexing returning a NumPy array rather than a ``Series`` when indexing with a scalar like ``.loc['2015']`` (:issue:`27516`)
- Break reference cycle involving :class:`Index` and other index classes to allow garbage collection of index objects without running the GC. (:issue:`27585`, :issue:`27840`)
- Fix regression in assigning values to a single column of a DataFrame with a ``MultiIndex`` columns (:issue:`27841`).
-
- Fix regression in ``.ix`` fallback with an ``IntervalIndex`` (:issue:`27865`).

Missing
^^^^^^^

-
-
-

MultiIndex
^^^^^^^^^^

-
-
-
- Bug in :func:`pandas.isnull` or :func:`pandas.isna` when the input is a type e.g. ``type(pandas.Series())`` (:issue:`27482`)

I/O
^^^

- Avoid calling ``S3File.s3`` when reading parquet, as this was removed in s3fs version 0.3.0 (:issue:`27756`)
- Better error message when a negative header is passed in :func:`pandas.read_csv` (:issue:`27779`)
-
- Follow the ``min_rows`` display option (introduced in v0.25.0) correctly in the HTML repr in the notebook (:issue:`27991`).

Plotting
^^^^^^^^

- Added a pandas_plotting_backends entrypoint group for registering plot backends. See :ref:`extending.plotting-backends` for more (:issue:`26747`).
- Added a ``pandas_plotting_backends`` entrypoint group for registering plot backends. See :ref:`extending.plotting-backends` for more (:issue:`26747`).
- Fixed the re-instatement of Matplotlib datetime converters after calling
:meth:`pandas.plotting.deregister_matplotlib_converters` (:issue:`27481`).
- Fix compatibility issue with matplotlib when passing a pandas ``Index`` to a plot call (:issue:`27775`).
-

Groupby/resample/rolling
^^^^^^^^^^^^^^^^^^^^^^^^

- Fixed regression in :meth:`pands.core.groupby.DataFrameGroupBy.quantile` raising when multiple quantiles are given (:issue:`27526`)
- Bug in :meth:`pandas.core.groupby.DataFrameGroupBy.transform` where applying a timezone conversion lambda function would drop timezone information (:issue:`27496`)
- Bug in :meth:`pandas.core.groupby.GroupBy.nth` where ``observed=False`` was being ignored for Categorical groupers (:issue:`26385`)
- Bug in windowing over read-only arrays (:issue:`27766`)
- Fixed segfault in `pandas.core.groupby.DataFrameGroupBy.quantile` when an invalid quantile was passed (:issue:`27470`)
-

Reshaping
^^^^^^^^^

- A ``KeyError`` is now raised if ``.unstack()`` is called on a :class:`Series` or :class:`DataFrame` with a flat :class:`Index` passing a name which is not the correct one (:issue:`18303`)
- Bug :meth:`merge_asof` could not merge :class:`Timedelta` objects when passing `tolerance` kwarg (:issue:`27642`)
- Bug in :meth:`DataFrame.crosstab` when ``margins`` set to ``True`` and ``normalize`` is not ``False``, an error is raised. (:issue:`27500`)
- :meth:`DataFrame.join` now suppresses the ``FutureWarning`` when the sort parameter is specified (:issue:`21952`)
- Bug in :meth:`DataFrame.join` raising with readonly arrays (:issue:`27943`)

Sparse
^^^^^^
- Bug in reductions for :class:`Series` with Sparse dtypes (:issue:`27080`)
-
-
-


Build Changes
^^^^^^^^^^^^^

-
-
-

ExtensionArray
^^^^^^^^^^^^^^

-
-
-
- Bug in reductions for :class:`Series` with Sparse dtypes (:issue:`27080`)

Other
^^^^^

- Bug in :meth:`Series.replace` and :meth:`DataFrame.replace` when replacing timezone-aware timestamps using a dict-like replacer (:issue:`27720`)
-
-
-
- Bug in :meth:`Series.rename` when using a custom type indexer. Now any value that isn't callable or dict-like is treated as a scalar. (:issue:`27814`)

.. _whatsnew_0.251.contributors:

Expand Down
110 changes: 110 additions & 0 deletions doc/source/whatsnew/v0.25.2.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
.. _whatsnew_0252:

What's new in 0.25.2 (October XX, 2019)
---------------------------------------

These are the changes in pandas 0.25.2. See :ref:`release` for a full changelog
including other versions of pandas.

.. _whatsnew_0252.bug_fixes:

Bug fixes
~~~~~~~~~

Categorical
^^^^^^^^^^^

-

Datetimelike
^^^^^^^^^^^^

-
-
-

Timezones
^^^^^^^^^

-

Numeric
^^^^^^^

-
-
-
-

Conversion
^^^^^^^^^^

-

Interval
^^^^^^^^

-

Indexing
^^^^^^^^

-
-
-
-

Missing
^^^^^^^

-

I/O
^^^

-
-
-

Plotting
^^^^^^^^

-
-
-

Groupby/resample/rolling
^^^^^^^^^^^^^^^^^^^^^^^^

-
-
-
-
-

Reshaping
^^^^^^^^^

-
-
-
-
-

Sparse
^^^^^^

-

Other
^^^^^

-
-

.. _whatsnew_0.252.contributors:

Contributors
~~~~~~~~~~~~

.. contributors:: v0.25.1..HEAD

0 comments on commit 1e3df80

Please sign in to comment.