Skip to content

Commit

Permalink
Refine curvefit doctest (#8328)
Browse files Browse the repository at this point in the history
A very small change
  • Loading branch information
max-sixty authored Oct 18, 2023
1 parent 88285f9 commit c25c825
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions xarray/core/dataarray.py
Original file line number Diff line number Diff line change
Expand Up @@ -6280,7 +6280,7 @@ def curvefit(
>>> def exp_decay(t, time_constant, amplitude):
... return np.exp(-t / time_constant) * amplitude
...
>>> t = np.linspace(0, 10, 11)
>>> t = np.arange(11)
>>> da = xr.DataArray(
... np.stack(
... [
Expand All @@ -6305,7 +6305,7 @@ def curvefit(
0.00910995]])
Coordinates:
* x (x) int64 0 1 2
* time (time) float64 0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0
* time (time) int64 0 1 2 3 4 5 6 7 8 9 10
Fit the exponential decay function to the data along the ``time`` dimension:
Expand Down

0 comments on commit c25c825

Please sign in to comment.