8000 DOC : minor changes to linspace docstring · numpy/numpy@14a3dca · GitHub
[go: up one dir, main page]

Skip to content

Commit 14a3dca

Browse files
tacaswelljuliantaylor
authored andcommitted
DOC : minor changes to linspace docstring
- added optional flag to dtype - moved conditional on step to the description from the type
1 parent b40e686 commit 14a3dca

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

numpy/core/function_base.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def linspace(start, stop, num=50, endpoint=True, retstep=False, dtype=None):
3232
retstep : bool, optional
3333
If True, return (`samples`, `step`), where `step` is the spacing
3434
between samples.
35-
dtype : dtype
35+
dtype : dtype, optional
3636
The type of the output array. If `dtype` is not given, infer the data
3737
type from the other input arguments.
3838
@@ -42,7 +42,9 @@ def linspace(start, stop, num=50, endpoint=True, retstep=False, dtype=None):
4242
There are `num` equally spaced samples in the closed interval
4343
``[start, stop]`` or the half-open interval ``[start, stop)``
4444
(depending on whether `endpoint` is True or False).
45-
step : float (only if `retstep` is True)
45+
step : float
46+
Only returned if `retstep` is True
47+
4648
Size of spacing between samples.
4749
4850

0 commit comments

Comments
 (0)
0