differt.plotting.draw_markers

Contents

differt.plotting.draw_markers#

draw_markers(markers, labels=None, text_kwargs=None, **kwargs)[source]#

Plot markers and, optionally, their label.

Parameters:
Return type:

Any

Returns:

The resulting plot output.

Warning

Matplotlib does not support labels.

Examples

The following example shows how to plot several annotated markers.

>>> from differt.plotting import draw_markers
>>>
>>> markers = np.array([
...     [0.0, 0.0, 0.0],
...     [1.0, 0.0, 0.0],
...     [1.0, 1.0, 0.0],
...     [0.0, 1.0, 0.0],
... ])
>>> labels = ["A", "B", "C", "D"]
>>> fig = draw_markers(markers, labels, backend="plotly")
>>> fig