Skip to content

DOC: Autoreformat all docstrings. #5122

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 7, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions xarray/core/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -490,9 +490,9 @@ def assign_attrs(self, *args, **kwargs):

Parameters
----------
args
*args
positional arguments passed into ``attrs.update``.
kwargs
**kwargs
keyword arguments passed into ``attrs.update``.

Returns
Expand Down Expand Up @@ -527,9 +527,9 @@ def pipe(
Alternatively a ``(callable, data_keyword)`` tuple where
``data_keyword`` is a string indicating the keyword of
``callable`` that expects the xarray object.
args
*args
positional arguments passed into ``func``.
kwargs
**kwargs
a dictionary of keyword arguments passed into ``func``.

Returns
Expand Down
2 changes: 1 addition & 1 deletion xarray/core/computation.py
Original file line number Diff line number Diff line change
Expand Up @@ -1355,7 +1355,7 @@ def dot(*arrays, dims=None, **kwargs):

Parameters
----------
arrays : DataArray or Variable
*arrays : DataArray or Variable
Arrays to compute.
dims : ..., str or tuple of str, optional
Which dimensions to sum over. Ellipsis ('...') sums over all dimensions.
Expand Down
4 changes: 2 additions & 2 deletions xarray/core/dask_array_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ def ensure_minimum_chunksize(size, chunks):

Parameters
----------
size: int
size : int
The maximum size of any chunk.
chunks: tuple
chunks : tuple
Chunks along one axis, e.g. ``(3, 3, 2)``

Examples
Expand Down
11 changes: 4 additions & 7 deletions xarray/core/dataarray.py
Original file line number Diff line number Diff line change
Expand Up @@ -2131,9 +2131,6 @@ def to_unstacked_dataset(self, dim, level=0):
level : int or str
The MultiIndex level to expand to a dataset along. Can either be
the integer index of the level or its name.
label : int, default: 0
Label of the level to expand dataset along. Overrides the label
argument if given.

Returns
-------
Expand Down Expand Up @@ -2455,7 +2452,7 @@ def interpolate_na(
If True, the dataarray's attributes (`attrs`) will be copied from
the original object to the new one. If False, the new
object will be returned without attributes.
kwargs : dict, optional
**kwargs : dict, optional
parameters passed verbatim to the underlying interpolation function

Returns
Expand Down Expand Up @@ -4379,7 +4376,7 @@ def query(
The default of 'pandas' parses code slightly different than standard
Python. Alternatively, you can parse an expression using the 'python'
parser to retain strict Python semantics.
engine: {"python", "numexpr", None}, default: None
engine : {"python", "numexpr", None}, default: None
The engine used to evaluate the expression. Supported engines are:
- None: tries to use numexpr, falls back to python
- "numexpr": evaluates expressions using numexpr
Expand Down Expand Up @@ -4462,7 +4459,7 @@ def curvefit(
Optional dictionary of parameter names to bounding values passed to the
`curve_fit` `bounds` arg. If none or only some parameters are passed, the rest
will be unbounded following the default scipy behavior.
param_names: seq, optional
param_names : seq, optional
Sequence of names for the fittable parameters of `func`. If not supplied,
this will be automatically determined by arguments of `func`. `param_names`
should be manually supplied when fitting a function that takes a variable
Expand All @@ -4480,7 +4477,7 @@ def curvefit(
[var]_curvefit_covariance
The covariance matrix of the coefficient estimates.

See also
See Also
--------
DataArray.polyfit
scipy.optimize.curve_fit
Expand Down
8 changes: 4 additions & 4 deletions xarray/core/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -4568,7 +4568,7 @@ def interpolate_na(
* x (x) int64 0 1 2 3 4 5 6 7 8

The gap lengths are 3-0 = 3; 6-3 = 3; and 8-6 = 2 respectively
kwargs : dict, optional
**kwargs : dict, optional
parameters passed verbatim to the underlying interpolation function

Returns
Expand Down Expand Up @@ -7087,7 +7087,7 @@ def query(
The default of 'pandas' parses code slightly different than standard
Python. Alternatively, you can parse an expression using the 'python'
parser to retain strict Python semantics.
engine: {"python", "numexpr", None}, default: None
engine : {"python", "numexpr", None}, default: None
The engine used to evaluate the expression. Supported engines are:
- None: tries to use numexpr, falls back to python
- "numexpr": evaluates expressions using numexpr
Expand Down Expand Up @@ -7178,7 +7178,7 @@ def curvefit(
Optional dictionary of parameter names to bounding values passed to the
`curve_fit` `bounds` arg. If none or only some parameters are passed, the rest
will be unbounded following the default scipy behavior.
param_names: seq, optional
param_names : seq, optional
Sequence of names for the fittable parameters of `func`. If not supplied,
this will be automatically determined by arguments of `func`. `param_names`
should be manually supplied when fitting a function that takes a variable
Expand All @@ -7196,7 +7196,7 @@ def curvefit(
[var]_curvefit_covariance
The covariance matrix of the coefficient estimates.

See also
See Also
--------
Dataset.polyfit
scipy.optimize.curve_fit
Expand Down
8 changes: 4 additions & 4 deletions xarray/plot/facetgrid.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ def map_dataarray(self, func, x, y, **kwargs):
plotting method such as `xarray.plot.imshow`
x, y : string
Names of the coordinates to plot on x, y axes
kwargs
**kwargs
additional keyword arguments to func

Returns
Expand Down Expand Up @@ -507,7 +507,7 @@ def set_titles(self, template="{coord} = {value}", maxchar=30, size=None, **kwar
Template for plot titles containing {coord} and {value}
maxchar : int
Truncate titles at maxchar
kwargs : keyword args
**kwargs : keyword args
additional arguments to matplotlib.text

Returns
Expand Down Expand Up @@ -603,11 +603,11 @@ def map(self, func, *args, **kwargs):
must plot to the currently active matplotlib Axes and take a
`color` keyword argument. If faceting on the `hue` dimension,
it must also take a `label` keyword argument.
args : strings
*args : strings
Column names in self.data that identify variables with data to
plot. The data for each variable is passed to `func` in the
order the variables are specified in the call.
kwargs : keyword arguments
**kwargs : keyword arguments
All keyword arguments are passed to the plotting function.

Returns
Expand Down
2 changes: 1 addition & 1 deletion xarray/tutorial.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def open_dataset(
The directory in which to search for and write cached data.
cache : bool, optional
If True, then cache data locally for use on subsequent calls
kws : dict, optional
**kws : dict, optional
Passed to xarray.open_dataset

Notes
Expand Down