Skip to content

Commit

Permalink
updates for 0.14 release
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph Hamman committed Oct 14, 2019
1 parent 4f5ca73 commit 4519843
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 22 deletions.
2 changes: 1 addition & 1 deletion doc/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -614,8 +614,8 @@ Plotting
:toctree: generated/

Dataset.plot
plot.scatter
DataArray.plot
Dataset.plot.scatter
plot.plot
plot.contourf
plot.contour
Expand Down
35 changes: 17 additions & 18 deletions doc/whats-new.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ What's New
.. _whats-new.0.14.0:

v0.14.0 (unreleased)
--------------------
v0.14.0 (14 Oct 2019)
---------------------

Breaking changes
~~~~~~~~~~~~~~~~
Expand All @@ -42,42 +42,43 @@ Breaking changes

(:issue:`3222`, :issue:`3293`, :issue:`3340`, :issue:`3346`, :issue:`3358`).
By `Guido Imperiale <https://github.com/crusaderky>`_.
- Dropped the 'drop=False' optional parameter from :meth:`Variable.isel`.
It was unused and doesn't make sense for a Variable.
(:pull:`3375`) by `Guido Imperiale <https://github.com/crusaderky>`_.

- Dropped the `drop=False` optional parameter from :meth:`Variable.isel`.
It was unused and doesn't make sense for a Variable. (:pull:`3375`).
By `Guido Imperiale <https://github.com/crusaderky>`_.

- Remove internal usage of `collections.OrderedDict`. After dropping support for
Python <=3.5, most uses of `OrderedDict` in Xarray were no longer necessary. We
have removed the internal use of the `OrderedDict` in favor of Python's builtin
`dict` object which is now ordered itself. This change will be most obvious when
interacting with the `attrs` property on the Dataset and DataArray objects.

(:issue:`3380`, :issue:`3389`). By `Joe Hamman <https://github.com/jhamman>`_.
(:issue:`3380`, :pull:`3389`). By `Joe Hamman <https://github.com/jhamman>`_.

New functions/methods
~~~~~~~~~~~~~~~~~~~~~

- Added :py:func:`~xarray.map_blocks`, modeled after :py:func:`dask.array.map_blocks`.
Also added :py:meth:`Dataset.unify_chunks`, :py:meth:`DataArray.unify_chunks` and
:py:meth:`testing.assert_chunks_equal`. By `Deepak Cherian <https://github.com/dcherian>`_
and `Guido Imperiale <https://github.com/crusaderky>`_.
:py:meth:`testing.assert_chunks_equal`. (:pull:`3276`).
By `Deepak Cherian <https://github.com/dcherian>`_ and
`Guido Imperiale <https://github.com/crusaderky>`_.

Enhancements
~~~~~~~~~~~~

- :py:class:`~xarray.core.GroupBy` enhancements. By `Deepak Cherian <https://github.com/dcherian>`_.

- Added a repr. Example::
- Added a repr (:pull:`3344`). Example::

>>> da.groupby("time.season")
DataArrayGroupBy, grouped over 'season'
4 groups with labels 'DJF', 'JJA', 'MAM', 'SON'

- Added a ``GroupBy.dims`` property that mirrors the dimensions
of each group.(:issue:`3344`)
of each group (:issue:`3344`).

- Speed up :meth:`Dataset.isel` up to 33% and :meth:`DataArray.isel` up to 25% for small
arrays (:issue:`2799`, :pull:`3375`) by
arrays (:issue:`2799`, :pull:`3375`). By
`Guido Imperiale <https://github.com/crusaderky>`_.

Bug fixes
Expand Down Expand Up @@ -107,16 +108,14 @@ Documentation
By `Gregory Gundersen <https://github.com/gwgundersen/>`_.
- Created a "How do I..." section (:ref:`howdoi`) for solutions to common questions. (:pull:`3357`).
By `Deepak Cherian <https://github.com/dcherian/>`_.
- Add examples for :py:meth:`Dataset.swap_dims` and :py:meth:`DataArray.swap_dims`.
By `Justus Magin <https://github.com/keewis>`_.
- Add examples for :py:meth:`Dataset.swap_dims` and :py:meth:`DataArray.swap_dims`
(pull:`3331`, pull:`3331`). By `Justus Magin <https://github.com/keewis>`_.
- Add examples for :py:meth:`align`, :py:meth:`merge`, :py:meth:`combine_by_coords`,
:py:meth:`full_like`, :py:meth:`zeros_like`, :py:meth:`ones_like`, :py:meth:`Dataset.pipe`,
:py:meth:`Dataset.assign`, :py:meth:`Dataset.reindex`, :py:meth:`Dataset.fillna`.
:py:meth:`Dataset.assign`, :py:meth:`Dataset.reindex`, :py:meth:`Dataset.fillna` (pull:`3328`).
By `Anderson Banihirwe <https://github.com/andersy005>`_.
- Fixed documentation to clean up an unwanted file created in ``ipython`` example
(:pull:`3353`).
By `Gregory Gundersen <https://github.com/gwgundersen/>`_.

(:pull:`3353`). By `Gregory Gundersen <https://github.com/gwgundersen/>`_.

.. _whats-new.0.13.0:

Expand Down
2 changes: 1 addition & 1 deletion xarray/core/dataarray.py
Original file line number Diff line number Diff line change
Expand Up @@ -2543,7 +2543,7 @@ def _copy_attrs_from(self, other: Union["DataArray", Dataset, Variable]) -> None
@property
def plot(self) -> _PlotMethods:
"""
Access plotting functions
Access plotting functions for DataArray's
>>> d = DataArray([[1, 2], [3, 4]])
Expand Down
4 changes: 2 additions & 2 deletions xarray/core/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -5243,8 +5243,8 @@ def imag(self):
@property
def plot(self):
"""
Access plotting functions. Use it as a namespace to use
xarray.plot functions as Dataset methods
Access plotting functions for Datasets.
Use it as a namespace to use xarray.plot functions as Dataset methods
>>> ds.plot.scatter(...) # equivalent to xarray.plot.scatter(ds,...)
Expand Down
2 changes: 2 additions & 0 deletions xarray/plot/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from .facetgrid import FacetGrid
from .plot import contour, contourf, hist, imshow, line, pcolormesh, plot, step
from .dataset_plot import scatter

__all__ = [
"plot",
Expand All @@ -11,4 +12,5 @@
"imshow",
"pcolormesh",
"FacetGrid",
"scatter"
]

0 comments on commit 4519843

Please sign in to comment.