Skip to content
forked from pydata/xarray

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into apply-ufunc-example
Browse files Browse the repository at this point in the history
* upstream/master:
  Add nanmedian for dask arrays (pydata#3604)
  added pyinterp to related projects (pydata#3655)
  Allow incomplete hypercubes in combine_by_coords (pydata#3649)
  concat keeps attrs from first variable. (pydata#3637)
  Extend DatetimeAccessor properties and support `.dt` accessor for Timedelta (pydata#3612)
  update readthedocs.yml (pydata#3639)
  silence sphinx warnings round 3 (pydata#3602)
  Fix/quantile wrong errmsg (pydata#3635)
  Provide shape info in shape mismatch error. (pydata#3619)
  Minor doc fixes (pydata#3615)
  • Loading branch information
dcherian committed Dec 30, 2019
2 parents 9c10c98 + b3d3b44 commit ed06ad2
Show file tree
Hide file tree
Showing 31 changed files with 1,435 additions and 281 deletions.
653 changes: 652 additions & 1 deletion doc/api-hidden.rst

Large diffs are not rendered by default.

38 changes: 37 additions & 1 deletion doc/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ Top-level functions
ones_like
dot
map_blocks
show_versions
set_options

Dataset
=======
Expand Down Expand Up @@ -74,7 +76,9 @@ and values given by ``DataArray`` objects.
Dataset.__setitem__
Dataset.__delitem__
Dataset.update
Dataset.get
Dataset.items
Dataset.keys
Dataset.values

Dataset contents
Expand Down Expand Up @@ -537,6 +541,15 @@ DataArray methods
DataArray.unify_chunks
DataArray.map_blocks

Coordinates objects
===================

.. autosummary::
:toctree: generated/

core.coordinates.DataArrayCoordinates
core.coordinates.DatasetCoordinates

GroupBy objects
===============

Expand Down Expand Up @@ -564,6 +577,16 @@ Rolling objects
core.rolling.DatasetRolling.reduce
core.rolling_exp.RollingExp

Coarsen objects
===============

.. autosummary::
:toctree: generated/

core.rolling.DataArrayCoarsen
core.rolling.DatasetCoarsen


Resample objects
================

Expand Down Expand Up @@ -593,6 +616,7 @@ Accessors
:toctree: generated/

core.accessor_dt.DatetimeAccessor
core.accessor_dt.TimedeltaAccessor
core.accessor_str.StringAccessor

Custom Indexes
Expand Down Expand Up @@ -625,6 +649,7 @@ Plotting
plot.imshow
plot.line
plot.pcolormesh
plot.FacetGrid

Faceting
--------
Expand All @@ -644,6 +669,14 @@ Faceting
plot.FacetGrid.set_xlabels
plot.FacetGrid.set_ylabels

Tutorial
========

.. autosummary::
:toctree: generated/

tutorial.open_dataset
tutorial.load_dataset

Testing
=======
Expand Down Expand Up @@ -681,7 +714,7 @@ Advanced API

These backends provide a low-level interface for lazily loading data from
external file-formats or protocols, and can be manually invoked to create
arguments for the ``from_store`` and ``dump_to_store`` Dataset methods:
arguments for the ``load_store`` and ``dump_to_store`` Dataset methods:

.. autosummary::
:toctree: generated/
Expand All @@ -697,6 +730,9 @@ arguments for the ``from_store`` and ``dump_to_store`` Dataset methods:
Deprecated / Pending Deprecation
================================

.. autosummary::
:toctree: generated/

Dataset.drop
DataArray.drop
Dataset.apply
Expand Down
6 changes: 3 additions & 3 deletions doc/groupby.rst
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ Apply
~~~~~

To apply a function to each group, you can use the flexible
:py:meth:`~xarray.DatasetGroupBy.map` method. The resulting objects are automatically
:py:meth:`~xarray.core.groupby.DatasetGroupBy.map` method. The resulting objects are automatically
concatenated back together along the group axis:

.. ipython:: python
Expand All @@ -104,8 +104,8 @@ concatenated back together along the group axis:
arr.groupby('letters').map(standardize)
GroupBy objects also have a :py:meth:`~xarray.DatasetGroupBy.reduce` method and
methods like :py:meth:`~xarray.DatasetGroupBy.mean` as shortcuts for applying an
GroupBy objects also have a :py:meth:`~xarray.core.groupby.DatasetGroupBy.reduce` method and
methods like :py:meth:`~xarray.core.groupby.DatasetGroupBy.mean` as shortcuts for applying an
aggregation function:

.. ipython:: python
Expand Down
4 changes: 2 additions & 2 deletions doc/howdoi.rst
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ How do I ...
* - change the order of dimensions
- :py:meth:`DataArray.transpose`, :py:meth:`Dataset.transpose`
* - remove a variable from my object
- :py:meth:`Dataset.drop`, :py:meth:`DataArray.drop`
- :py:meth:`Dataset.drop_vars`, :py:meth:`DataArray.drop_vars`
* - remove dimensions of length 1 or 0
- :py:meth:`DataArray.squeeze`, :py:meth:`Dataset.squeeze`
* - remove all variables with a particular dimension
Expand All @@ -48,7 +48,7 @@ How do I ...
* - write xarray objects with complex values to a netCDF file
- :py:func:`Dataset.to_netcdf`, :py:func:`DataArray.to_netcdf` specifying ``engine="h5netcdf", invalid_netcdf=True``
* - make xarray objects look like other xarray objects
- :py:func:`~xarray.ones_like`, :py:func:`~xarray.zeros_like`, :py:func:`~xarray.full_like`, :py:meth:`Dataset.reindex_like`, :py:meth:`Dataset.interpolate_like`, :py:meth:`Dataset.broadcast_like`, :py:meth:`DataArray.reindex_like`, :py:meth:`DataArray.interpolate_like`, :py:meth:`DataArray.broadcast_like`
- :py:func:`~xarray.ones_like`, :py:func:`~xarray.zeros_like`, :py:func:`~xarray.full_like`, :py:meth:`Dataset.reindex_like`, :py:meth:`Dataset.interp_like`, :py:meth:`Dataset.broadcast_like`, :py:meth:`DataArray.reindex_like`, :py:meth:`DataArray.interp_like`, :py:meth:`DataArray.broadcast_like`
* - replace NaNs with other values
- :py:meth:`Dataset.fillna`, :py:meth:`Dataset.ffill`, :py:meth:`Dataset.bfill`, :py:meth:`Dataset.interpolate_na`, :py:meth:`DataArray.fillna`, :py:meth:`DataArray.ffill`, :py:meth:`DataArray.bfill`, :py:meth:`DataArray.interpolate_na`
* - extract the year, month, day or similar from a DataArray of time values
Expand Down
2 changes: 1 addition & 1 deletion doc/indexing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ use them explicitly to slice data. There are two ways to do this:
The arguments to these methods can be any objects that could index the array
along the dimension given by the keyword, e.g., labels for an individual value,
Python :py:func:`slice` objects or 1-dimensional arrays.
Python :py:class:`slice` objects or 1-dimensional arrays.

.. note::

Expand Down
4 changes: 2 additions & 2 deletions doc/interpolation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ array-like, which gives the interpolated result as an array.
# interpolation
da.interp(time=[2.5, 3.5])
To interpolate data with a :py:func:`numpy.datetime64` coordinate you can pass a string.
To interpolate data with a :py:doc:`numpy.datetime64 <reference/arrays.datetime>` coordinate you can pass a string.

.. ipython:: python
Expand Down Expand Up @@ -128,7 +128,7 @@ It is now possible to safely compute the difference ``other - interpolated``.
Interpolation methods
---------------------

We use :py:func:`scipy.interpolate.interp1d` for 1-dimensional interpolation and
We use :py:class:`scipy.interpolate.interp1d` for 1-dimensional interpolation and
:py:func:`scipy.interpolate.interpn` for multi-dimensional interpolation.

The interpolation method can be specified by the optional ``method`` argument.
Expand Down
Loading

0 comments on commit ed06ad2

Please sign in to comment.