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: doc/python/imshow.md
+26-5
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.2'
9
-
jupytext_version: 1.7.1
9
+
jupytext_version: 1.3.0
10
10
kernelspec:
11
11
display_name: Python 3
12
12
language: python
@@ -399,9 +399,9 @@ for compression_level in range(0, 9):
399
399
fig.show()
400
400
```
401
401
402
-
### Exploring 3-D imagesand timeseries with `facet_col`
402
+
### Exploring 3-D images, timeseries and sequences of images with `facet_col`
403
403
404
-
*Introduced in plotly 4.13*
404
+
*Introduced in plotly 4.14*
405
405
406
406
For three-dimensional image datasets, obtained for example by MRI or CT in medical imaging, one can explore the dataset by representing its different planes as facets. The `facet_col` argument specifies along which axis the image is sliced through to make the facets. With `facet_col_wrap`, one can set the maximum number of columns. For image datasets passed as xarrays, it is also possible to specify the axis by its name (label), thus passing a string to `facet_col`.
Facets can also be used to represent several images of equal shape, like in the example below where different values of the blurring parameter of a Gaussian filter are compared.
424
+
425
+
```python
426
+
import plotly.express as px
427
+
import numpy as np
428
+
from skimage import data, filters, img_as_float
429
+
img = data.camera()
430
+
sigmas = [1, 2, 4]
431
+
img_sequence = [filters.gaussian(img, sigma=sigma) for sigma in sigmas]
### Exploring 3-D images and timeseries with `animation_frame`
424
445
425
-
*Introduced in plotly 4.13*
446
+
*Introduced in plotly 4.14*
426
447
427
448
For three-dimensional image datasets, obtained for example by MRI or CT in medical imaging, one can explore the dataset by sliding through its different planes in an animation. The `animation_frame` argument of `px.imshow` sets the axis along which the 3-D image is sliced in the animation.
428
449
@@ -439,7 +460,7 @@ fig.show()
439
460
440
461
### Animations of xarray datasets
441
462
442
-
*Introduced in plotly 4.11*
463
+
*Introduced in plotly 4.14*
443
464
444
465
For xarray datasets, one can pass either an axis number or an axis name to `animation_frame`. Axis names and coordinates are automatically used for the labels, ticks and animation controls of the figure.
0 commit comments