ScatterGraphic#

ScatterGraphic#

Constructor#

ScatterGraphic(data[, colors, cmap, ...])

Create a Scatter Graphic, 2d or 3d

Properties#

ScatterGraphic.alpha

The opacity of the graphic

ScatterGraphic.alpha_mode

How the alpha is handled by the renderer

ScatterGraphic.axes

ScatterGraphic.block_events

Used to block events for a graphic and prevent recursion.

ScatterGraphic.block_handlers

Used to block event handlers for a graphic and prevent recursion.

ScatterGraphic.cmap

Get or set the colormap

ScatterGraphic.cmap_range

Get or set the (min, max) of the cmap_transform that is mapped onto the colormap

ScatterGraphic.cmap_transform

ScatterGraphic.colors

Get or set the colors

ScatterGraphic.data

Get or set the graphic's data.

ScatterGraphic.deleted

used to emit an event after the graphic is deleted

ScatterGraphic.edge_colors

Get or set the marker edge colors, if mode is 'markers'

ScatterGraphic.edge_width

Get or set the edge_width if mode is 'markers'

ScatterGraphic.event_handlers

Registered event handlers.

ScatterGraphic.image

Get or set the image data, returns None if scatter plot mode is not 'image'

ScatterGraphic.imgui_right_click

The imgui popup that is opened by a right-click on this graphic.

ScatterGraphic.legend_item

The legend item of this graphic, created with create_legend_item().

ScatterGraphic.markers

Get or set the markers, if mode is 'markers'

ScatterGraphic.mode

scatter point display mode

ScatterGraphic.name

Graphic name

ScatterGraphic.offset

[x, y, z]

ScatterGraphic.point_rotation_mode

point rotation mode, read-only, one of 'uniform', 'vertex', or 'curve'

ScatterGraphic.point_rotations

Get or set the point rotations in radians; returns None in 'curve' mode

ScatterGraphic.rotation

Orientation of the graphic as a quaternion

ScatterGraphic.scale

(x, y, z) scaling factor

ScatterGraphic.size_space

The coordinate space in which the size is expressed ('screen', 'world', 'model')

ScatterGraphic.sizes

Get or set the scatter point size(s)

ScatterGraphic.supported_events

events supported by this graphic

ScatterGraphic.tooltip_format

set a custom tooltip format function which takes a pick_info dict and returns a str to be displayed in the tooltip

ScatterGraphic.visible

Whether the graphic is visible

ScatterGraphic.world_object

Associated pygfx WorldObject.

Methods#

ScatterGraphic.add_axes()

Add axes onto this Graphic

ScatterGraphic.add_event_handler(*args)

Register an event handler.

ScatterGraphic.append_imgui_right_click([gui])

Append imgui elements to the right-click popup of this graphic.

ScatterGraphic.clear_event_handlers()

clear all event handlers added to this graphic

ScatterGraphic.create_legend_item([label, ...])

Create the ScatterLegendItem of this scatter, add it to a legend with Legend.add().

ScatterGraphic.format_pick_info(pick_info)

Takes a pygfx.PointerEvent and returns formatted pick info.

ScatterGraphic.map_model_to_world(position)

map position from model (data) space to world space, basically applies the world affine transform

ScatterGraphic.map_world_to_model(position)

map position from world space to model (data) space, basically applies the inverse world affine transform

ScatterGraphic.remove_event_handler(...)

remove a registered event handler

ScatterGraphic.remove_imgui_right_click()

Remove and return the right-click popup of this graphic

ScatterGraphic.rotate(alpha[, axis])

Rotate the Graphic with respect to the world.

ScatterGraphic.set_imgui_right_click([...])

Set the imgui popup that is opened by a right-click on this graphic, replaces the popup of the subplot or Figure for this graphic.