Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 71420d2 commit d75015cCopy full SHA for d75015c
1 file changed
lib/matplotlib/colorizer.py
@@ -826,10 +826,8 @@ def _ensure_cmap(cmap, accept_multivariate=False):
826
# this error message is a variant of _api.check_in_list but gives
827
# additional hints as to how to access multivariate colormaps
828
829
- raise ValueError(f"{cmap!r} is not a valid value for cmap"
830
- "; supported values for scalar colormaps are "
831
- f"{', '.join(map(repr, sorted(mpl.colormaps)))}\n"
832
- "See `matplotlib.bivar_colormaps()` and"
+ raise ValueError(_api.list_suggestion_error_msg('cmap', cmap, mpl.colormaps) +
+ "\nSee `matplotlib.bivar_colormaps()` and"
833
" `matplotlib.multivar_colormaps()` for"
834
" bivariate and multivariate colormaps")
835
0 commit comments