AlloViz.AlloViz.Elements.Nodes._is_level_reference¶
- Nodes._is_level_reference(key: Hashable, axis: int | Literal['index', 'columns', 'rows'] = 0) bool ¶
Test whether a key is a level reference for a given axis.
- To be considered a level reference, key must be a string that:
(axis=0): Matches the name of an index level and does NOT match a column label.
(axis=1): Matches the name of a column level and does NOT match an index label.
- Parameters:
- keyHashable
Potential level name for the given axis
- axisint, default 0
Axis that levels are associated with (0 for index, 1 for columns)
- Returns:
- is_levelbool