graphical.cell
PlotCellRenderer
Renderer for plot cells.
Source code in src/graphical/cell.py
render(value, value_range, cell_style, invert=False, match_inverted=False)
staticmethod
Render plot cell.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
value
|
float
|
Value of the cell. |
required |
value_range
|
Tuple[float, float]
|
Value range of the cell. |
required |
cell_style
|
PlotCellStyle
|
Data representation syle.. |
required |
invert
|
bool
|
Invert cell direction. Defaults to False. |
False
|
match_inverted
|
bool
|
Use limited resolution to match inverted cells. Defaults to False. |
False
|
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
Char for plot cell. |
Source code in src/graphical/cell.py
PlotCellStyle
Bases: Enum
Cell styles for plot charts.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
chars
|
str
|
String of chars for values in ascending order. |
required |
under
|
str
|
Char for value ranges under the value. |
required |
over
|
str
|
Char for value ranges over the value. |
required |
matched
|
str
|
String of chars for values in ascending order matching the length of inverted. Reverts to chars. |
required |
inverted
|
str
|
String of chars for values in descending order. Reverts to chars. |
required |
Source code in src/graphical/cell.py
BAR_HEAVY_H = (' ╸━', ' ', '━', None, '━╺ ')
class-attribute
instance-attribute
Cell for horizontal heavy bar plots.
BAR_HEAVY_V = (' ╻┃', ' ', '┃', None, '┃╹ ')
class-attribute
instance-attribute
Cell for vertical heavy bar plots.
BAR_LIGHT_H = (' ╴─', ' ', '─', None, '─╶ ')
class-attribute
instance-attribute
Cell for horizontal light bar plots.
BAR_LIGHT_V = (' ╷│', ' ', '│', None, '│╵ ')
class-attribute
instance-attribute
Cell for vertical light bar plots.
BLOCK_H = (' ▏▎▍▌▋▊▉█', ' ', '█', ' ▕▕▐▐▐▐██', '██▐▐▐▕▕▕ ')
class-attribute
instance-attribute
Cell for horizontal area or full-width bar plots.
BLOCK_V = (' ▁▂▃▄▅▆▇█', ' ', '█', ' ▁▁▄▄▄▄██', '██▀▀▀▔▔▔ ')
class-attribute
instance-attribute
Cell for vertical area or full-width bar plots.
LINE_H = ('▏│▕', ' ', ' ', None, None)
class-attribute
instance-attribute
Cell for horizontal line plots.
LINE_V = (' ▁⎽⎼─⎻⎺▔', ' ', ' ', None, None)
class-attribute
instance-attribute
Cell for vertical line plots.
SHADE = (' ░▒▓█', ' ', '█', None, '█▓▒░ ')
class-attribute
instance-attribute
Cell for shading.