pyriemann.utils.viz.plot_embedding¶
- pyriemann.utils.viz.plot_embedding(X, y=None, *, embd_type='Spectral', metric='riemann', title='Embedding of SPD matrices', normalize=True, max_iter=50)¶
Plot embedding of SPD matrices.
- Parameters:
- Xndarray, shape (n_matrices, n_channels, n_channels)
Set of SPD matrices.
- yNone | ndarray, shape (n_matrices,), default=None
Labels for each matrix.
- embd_type{“Spectral”, “LocallyLinear”, “TSNE”}, default=”Spectral”
Type of the embedding.
- metricstring, default=”riemann”
Metric used for the embedding. Can be:
“riemann”, “logeuclid”, “euclid”, “logdet”, “kullback”, “kullback_right”, “kullback_sym” for Spectral Embedding;
“riemann”, “logeuclid”, “euclid” for Locally Linear Embedding;
“riemann”, “logeuclid”, “euclid” for TSNE.
- titlestr, default=”Embedding of SPD matrices”
Title of figure.
- normalizebool, default=True
If True, the plot is normalized from -1 to +1.
- max_iterint, default=50
Maximum number of iterations used for the gradient descent of TSNE.
- Returns:
- figmatplotlib figure
Figure of embedding.
Notes
Added in version 0.2.6.