Closed
Description
Bug report
Bug summary
edgecolors
is an explicit kwarg to plt.scatter()
. However edgecolor
kwarg takes precedence over it, although the function used to obtain the edgecolors (self._parse_scatter_color_args()
) documents that edgecolors
should take precedence:
Argument precedence for edgecolors:
edgecolors (is an explicit kw argument in scatter())
kwargs['edgecolor']
kwargs['color'] (==kwcolor)
'face' if not in classic mode else None
This also reproduces when substituting edgecolor
with ec
.
Code for reproduction
import matplotlib.pyplot as plt
c = plt.scatter([], [], edgecolors=[0,1,0,1], edgecolor=[1,0,0,1])
c.get_edgecolors()
Actual outcome
array([[1., 0., 0., 1.]])
Expected outcome
array([[0., 1., 0., 1.]])
Matplotlib version
- Operating system: macOS
- Matplotlib version: 3.3.1
- Matplotlib backend (
print(matplotlib.get_backend())
): MacOSX - Python version: 3.8.5
- Jupyter version (if applicable):
- Other libraries:
Installed from conda-forge