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/images.md
+18-24Lines changed: 18 additions & 24 deletions
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,7 @@ jupyter:
34
34
35
35
#### Add a Background Image
36
36
37
-
In this page we explain how to add static, non-interactive images as background, logo or annotation images to a figure. For exploring image data in interactive charts, see the [tutorial on displaying image data](./imshow/).
37
+
In this page we explain how to add static, non-interactive images as background, logo or annotation images to a figure. For exploring image data in interactive charts, see the [tutorial on displaying image data](/python/imshow).
Copy file name to clipboardExpand all lines: python/imshow.md
+7-4Lines changed: 7 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,10 @@ jupyter:
37
37
v4upgrade: true
38
38
---
39
39
40
+
This tutorial shows how to display and explore image data. If you would like
41
+
instead a logo or static image, use `go.layout.Image` as explained
42
+
[here](/python/images).
43
+
40
44
### Displaying RBG image data with px.imshow
41
45
42
46
`px.imshow` displays multichannel (RGB) or single-channel ("grayscale") image data.
@@ -73,7 +77,7 @@ fig.show()
73
77
74
78
### Display single-channel 2D image as grayscale
75
79
76
-
For a 2D image, `px.imshows` uses a colorscale to map scalar data to colors. The default colorscale is `gray`, ie grayscale images.
80
+
For a 2D image, `px.imshow` uses a colorscale to map scalar data to colors. The default colorscale is `gray`, ie grayscale images.
77
81
78
82
```python
79
83
import plotly.express as px
@@ -85,7 +89,6 @@ fig.show()
85
89
86
90
### Choose the colorscale to display a single-channel image
87
91
88
-
For a 2D image, `px.imshows` uses a colorscale to map scalar data to colors. The default colorscale is `gray`, ie grayscale images.
89
92
90
93
```python
91
94
import plotly.express as px
@@ -97,9 +100,9 @@ fig.show()
97
100
98
101
### Display multichannel image data with go.Image
99
102
100
-
It is also possible to use the `go.Image` trace from the low-level `graph_objects` API in order to display image data. Note that `go.Image` only accepts multichannel images. For single images, use [`go.Heatmap`](https://plot.ly/python/heatmaps/).
103
+
It is also possible to use the `go.Image` trace from the low-level `graph_objects` API in order to display image data. Note that `go.Image` only accepts multichannel images. For single images, use [`go.Heatmap`](/python/heatmaps).
101
104
102
-
Note that the `go.Image` trace is different from the `go.layout.Image` class, which can be used for [adding background images or logos to figures](./images/).
105
+
Note that the `go.Image` trace is different from the `go.layout.Image` class, which can be used for [adding background images or logos to figures](/python/images).
0 commit comments