
matplotlib.markers¶This module contains functions to handle markers. Used by both themarker functionality ofplot andscatter.
All possible markers are defined here:
| marker | description |
|---|---|
"." | point |
"," | pixel |
"o" | circle |
"v" | triangle_down |
"^" | triangle_up |
"<" | triangle_left |
">" | triangle_right |
"1" | tri_down |
"2" | tri_up |
"3" | tri_left |
"4" | tri_right |
"8" | octagon |
"s" | square |
"p" | pentagon |
"P" | plus (filled) |
"*" | star |
"h" | hexagon1 |
"H" | hexagon2 |
"+" | plus |
"x" | x |
"X" | x (filled) |
"D" | diamond |
"d" | thin_diamond |
"|" | vline |
"_" | hline |
| TICKLEFT | tickleft |
| TICKRIGHT | tickright |
| TICKUP | tickup |
| TICKDOWN | tickdown |
| CARETLEFT | caretleft (centered at tip) |
| CARETRIGHT | caretright (centered at tip) |
| CARETUP | caretup (centered at tip) |
| CARETDOWN | caretdown (centered at tip) |
| CARETLEFTBASE | caretleft (centered at base) |
| CARETRIGHTBASE | caretright (centered at base) |
| CARETUPBASE | caretup (centered at base) |
"None","" or"" | nothing |
'$...$' | render the string using mathtext. |
verts | a list of (x, y) pairs used for Path vertices.The center of the marker is located at (0,0) andthe size is normalized. |
| path | aPath instance. |
(numsides,style,angle) | The marker can also be a tuple (
|
For backward compatibility, the form (verts, 0) is also accepted,but it is equivalent to justverts for giving a raw set of verticesthat define the shape.
None is the default which means ‘nothing’, however this table isreferred to from other docs for the valid inputs from marker inputs and inthose casesNone still means ‘default’.
matplotlib.markers.MarkerStyle(marker=None,fillstyle=None)¶Bases:object
| Parameters: | marker : string or array_like, optional, default: None
fillstyle : string, optional, default: ‘full’
|
|---|
Attributes
| markers | (list of known markes) |
| fillstyles | (list of known fillstyles) |
| filled_markers | (list of known filled markers.) |
filled_markers = ('o', 'v', '^', '<', '>', '8', 's', 'p', '*', 'h', 'H', 'D', 'd', 'P', 'X')¶fillstyles = ('full', 'left', 'right', 'bottom', 'top', 'none')¶get_alt_path()¶get_alt_transform()¶get_capstyle()¶get_fillstyle()¶get_joinstyle()¶get_marker()¶get_path()¶get_snap_threshold()¶get_transform()¶is_filled()¶markers = {'.': 'point', ',': 'pixel', 'o': 'circle', 'v': 'triangle_down', '^': 'triangle_up', '<': 'triangle_left', '>': 'triangle_right', '1': 'tri_down', '2': 'tri_up', '3': 'tri_left', '4': 'tri_right', '8': 'octagon', 's': 'square', 'p': 'pentagon', '*': 'star', 'h': 'hexagon1', 'H': 'hexagon2', '+': 'plus', 'x': 'x', 'D': 'diamond', 'd': 'thin_diamond', '|': 'vline', '_': 'hline', 'P': 'plus_filled', 'X': 'x_filled', 0: 'tickleft', 1: 'tickright', 2: 'tickup', 3: 'tickdown', 4: 'caretleft', 5: 'caretright', 6: 'caretup', 7: 'caretdown', 8: 'caretleftbase', 9: 'caretrightbase', 10: 'caretupbase', 11: 'caretdownbase', 'None': 'nothing', None: 'nothing', ' ': 'nothing', '': 'nothing'}¶set_fillstyle(fillstyle)¶Sets fillstyle
| Parameters: | fillstyle : string amongst known fillstyles |
|---|
set_marker(marker)¶