FeaturesHistogramWidget#

class napari_matplotlib.FeaturesHistogramWidget(napari_viewer: napari.Viewer, parent: QWidget | None = None)#

Bases: SingleAxesWidget

Display a histogram of selected feature attached to selected layer.

Attributes Summary

input_layer_types

Type of layer taken as input

n_layers_input

Number of layers taken as input

x_axis_key

Key to access x axis data from the FeaturesTable

Methods Summary

draw()

Clear the axes and histogram the currently selected layer/slice.

on_update_layers()

Called when the layer selection changes by self.update_layers().

Attributes Documentation

input_layer_types: tuple[Layer, ...] = (<class 'napari.layers.labels.labels.Labels'>, <class 'napari.layers.points.points.Points'>, <class 'napari.layers.shapes.shapes.Shapes'>, <class 'napari.layers.tracks.tracks.Tracks'>, <class 'napari.layers.vectors.vectors.Vectors'>)#

Type of layer taken as input

n_layers_input = Interval(1, 1)#

Number of layers taken as input

x_axis_key#

Key to access x axis data from the FeaturesTable

Methods Documentation

draw() None#

Clear the axes and histogram the currently selected layer/slice.

on_update_layers() None#

Called when the layer selection changes by self.update_layers().