trackpy.annotate

trackpy.annotate(centroids, image, circle_size=None, color=None, invert=False, ax=None, split_category=None, split_thresh=None, imshow_style={}, plot_style={})

Mark identified features with white circles.

Parameters:

centroids : DataFrame including columns x and y

image : image array (or string path to image file)

circle_size : Deprecated.

This will be removed in a future version of trackpy. Use plot_style={‘markersize’: ...} instead.

color : single matplotlib color or a list of multiple colors

default None

invert : If you give a filepath as the image, specify whether to invert

black and white. Default True.

ax : matplotlib axes object, defaults to current axes

split_category : string, parameter to use to split the data into sections

default None

split_thresh : single value or list of ints or floats to split

particles into sections for plotting in multiple colors. List items should be ordered by increasing value. default None

imshow_style : dictionary of keyword arguments passed through to

the Axes.imshow(...) command the displays the image

plot_style : dictionary of keyword arguments passed through to

the Axes.plot(...) command that marks the features

Returns:

Axes object

See also

annotate3d
The 3D equivalent that returns a scrollable stack.