Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5ffd20d

Browse files
committed
Merge pull request #7096 from NelleV/7083_doc_scatter_vs_plot
[MRG] DOC refer to plot in the scatter plot doc
1 parent 2fe9e32 commit 5ffd20d

1 file changed

Lines changed: 17 additions & 9 deletions

File tree

lib/matplotlib/axes/_axes.py

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3891,17 +3891,25 @@ def scatter(self, x, y, s=None, c=None, marker=None, cmap=None, norm=None,
38913891
----------------
38923892
kwargs : `~matplotlib.collections.Collection` properties
38933893
3894+
See Also
3895+
--------
3896+
plot : to plot scatter plots when markers are identical in size and
3897+
color
3898+
38943899
Notes
3895-
------
3896-
Any or all of `x`, `y`, `s`, and `c` may be masked arrays, in
3897-
which case all masks will be combined and only unmasked points
3898-
will be plotted.
3900+
-----
3901+
3902+
* The `plot` function will be faster for scatterplots where markers
3903+
don't vary in size or color.
3904+
3905+
* Any or all of `x`, `y`, `s`, and `c` may be masked arrays, in which
3906+
case all masks will be combined and only unmasked points will be
3907+
plotted.
38993908
3900-
Fundamentally, scatter works with 1-D arrays; `x`, `y`, `s`,
3901-
and `c` may be input as 2-D arrays, but within scatter
3902-
they will be flattened. The exception is `c`, which
3903-
will be flattened only if its size matches the size of `x`
3904-
and `y`.
3909+
Fundamentally, scatter works with 1-D arrays; `x`, `y`, `s`, and `c`
3910+
may be input as 2-D arrays, but within scatter they will be
3911+
flattened. The exception is `c`, which will be flattened only if its
3912+
size matches the size of `x` and `y`.
39053913
39063914
Examples
39073915
--------

0 commit comments

Comments
 (0)