You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: python/colorscales.md
+39-4Lines changed: 39 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ jupyter:
6
6
extension: .md
7
7
format_name: markdown
8
8
format_version: '1.1'
9
-
jupytext_version: 1.1.1
9
+
jupytext_version: 1.2.1
10
10
kernelspec:
11
11
display_name: Python 3
12
12
language: python
@@ -20,7 +20,7 @@ jupyter:
20
20
name: python
21
21
nbconvert_exporter: python
22
22
pygments_lexer: ipython3
23
-
version: 3.6.8
23
+
version: 3.7.3
24
24
plotly:
25
25
description: How to set colorscales and heatmap colorscales in Python and Plotly.
26
26
Divergent, sequential, and qualitative colorscales.
@@ -32,8 +32,8 @@ jupyter:
32
32
name: Colorscales
33
33
order: 22
34
34
permalink: python/colorscales/
35
-
thumbnail: thumbnail/heatmap_colorscale.jpg
36
35
redirect_from: python/logarithmic-color-scale/
36
+
thumbnail: thumbnail/heatmap_colorscale.jpg
37
37
v4upgrade: true
38
38
---
39
39
@@ -196,6 +196,41 @@ fig.add_trace(go.Heatmap(
196
196
fig.show()
197
197
```
198
198
199
+
### Colorscale Midpoint
200
+
The following example uses [cmid](https://plot.ly/python/reference/#scatter-marker-cmid) attribute to set the mid-point of the color domain by scaling [cmin](https://plot.ly/python/reference/#scatter-marker-cmin) and/or [cmax](https://plot.ly/python/reference/#scatter-marker-cmax) to be equidistant to this point. It only has impact when [marker.line.color](https://plot.ly/python/reference/#scattercarpet-marker-line-color) sets to a numerical array, and [marker.line.cauto](https://plot.ly/python/reference/#scattercarpet-marker-line-cauto) is `True`. The heatmap chart uses [zmid](https://plot.ly/python/reference/#heatmap-zmid) attribute to set the mid-point of the color domain by scaling [zmin](https://plot.ly/python/reference/#heatmap-zmin) and/or [zmax](https://plot.ly/python/reference/#heatmap-zmax) to be equidistant to this point.
0 commit comments