matplotlib 3.5.1

Parameters
__init__(self, offsetbox, xy, xybox=None, xycoords='data', boxcoords=None, frameon=True, pad=0.4, annotation_clip=None, box_alignment=(0.5, 0.5), bboxprops=None, arrowprops=None, fontsize=None, **kwargs)

Parameters

offsetbox : `OffsetBox`
xy : (float, float)

The point (x, y) to annotate. The coordinate system is determined by xycoords.

xybox : (float, float), default: *xy*

The position (x, y) to place the text at. The coordinate system is determined by boxcoords.

xycoords : str or `.Artist` or `.Transform` or callable or (float, float), default: 'data'

The coordinate system that xy is given in. See the parameter xycoords in .Annotation for a detailed description.

boxcoords : str or `.Artist` or `.Transform` or callable or (float, float), default: value of *xycoords*

The coordinate system that xybox is given in. See the parameter textcoords in .Annotation for a detailed description.

frameon : bool, default: True

Whether to draw a frame around the box.

pad : float, default: 0.4

Padding around the offsetbox.

box_alignment : (float, float)

A tuple of two floats for a vertical and horizontal alignment of the offset box w.r.t. the boxcoords. The lower-left corner is (0, 0) and upper-right corner is (1, 1).

**kwargs :

Other parameters are identical to .Annotation .

Examples

See :

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


File: /matplotlib/offsetbox.py#1291
type: <class 'function'>
Commit: