graphinglib.Point.__init__#
- Point.__init__(x: float, y: float, label: str | None = None, face_color: str | None | Inherit = Inherit, edge_color: str | None | Inherit = Inherit, marker_size: float | Inherit = Inherit, marker_style: str | Inherit = Inherit, edge_width: float | Inherit = Inherit, alpha: float | Inherit = Inherit, font_size: int | Literal['same as figure'] = 'same as figure', text_color: str | Inherit = Inherit, h_align: str = 'left', v_align: str = 'bottom') None[source]#
This class implements a point object.
The point object can be used to show important coordinates in a plot or add a label to some point.
- Parameters:
- x, yfloat
The x and y coordinates of the
Point.- labelstr, optional
Label to be attached to the
Point.- face_colorstr or None
Face color of the marker. Default depends on the
figure_styleconfiguration.- edge_colorstr or None
Edge color of the marker. Default depends on the
figure_styleconfiguration.- marker_sizefloat
Size of the marker. Typical range is
10to100. Default depends on thefigure_styleconfiguration.- marker_stylestr
Style of the marker. Values include
".",",","o","v","^","<",">","s","p","*","h","H","+","x","D","d","|", and"_". Default depends on thefigure_styleconfiguration.- edge_widthfloat
Edge width of the marker. Typical range is
0to3. Default depends on thefigure_styleconfiguration.- alphafloat
Opacity of the point. Range is
0(transparent) to1(opaque). Default depends on thefigure_styleconfiguration.- font_sizefloat
Font size for the text attached to the marker. Typical range is
8to20. Default depends on thefigure_styleconfiguration.- text_colorstr
Color of the text attached to the marker. “same as point” uses the color of the point (prioritize edge color, then face color). Default depends on the
figure_styleconfiguration.- h_align, v_alignstr
Horizontal and vertical alignment of the text attached to the
Point. Horizontal alignment values include"left","center", and"right". Vertical alignment values include"bottom","baseline","center","center_baseline", and"top". Defaults to bottom left.
Notes
Color parameters accept Matplotlib color formats: named colors (
"blue"), short color strings ("b"), hex strings ("#0000ff"), grayscale strings ("0.5"), and RGB/RGBA tuples with values between0and1((0, 0, 1)or(0, 0, 1, 0.5)).