8000 improved docstring for MultivarColormap · matplotlib/matplotlib@f4361ed · GitHub
[go: up one dir, main page]

Skip to content
Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f4361ed

Browse files
committed
improved docstring for MultivarColormap
1 parent a2fb40c commit f4361ed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/matplotlib/colors.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1270,9 +1270,9 @@ def __init__(self, colormaps, combination_mode, name='multivariate colormap'):
12701270
Describe how colormaps are combined in sRGB space
12711271
12721272
- If 'sRGB_add' -> Mixing produces brighter colors
1273-
`sRGB = cmap[0][X[0]] + cmap[1][x[1]] + ... + cmap[n-1][x[n-1]]`
1273+
`sRGB = sum(colors)`
12741274
- If 'sRGB_sub' -> Mixing produces darker colors
1275-
`sRGB = cmap[0][X[0]] + cmap[1][x[1]] + ... + cmap[n-1][x[n-1]] - n + 1`
1275+
`sRGB = 1 - sum(1 - colors)`
12761276
name : str, optional
12771277
The name of the colormap family.
12781278
"""

0 commit comments

Comments
 (0)
0