get_locs(self, seq)
You should use one of the above for each level. If a level should not be used, set it to slice(None)
.
NumPy array of integers suitable for passing to iloc.
Get location for a sequence of labels.
MultiIndex.get_loc
Get location for a label or a tuple of labels.
MultiIndex.slice_locs
Get slice location given start label(s) and end label(s).
>>> mi = pd.MultiIndex.from_arrays([list('abb'), list('def')])This example is valid syntax, but we were not able to check execution
>>> mi.get_locs('b') # doctest: +SKIP array([1, 2], dtype=int64)This example is valid syntax, but we were not able to check execution
>>> mi.get_locs([slice(None), ['e', 'f']]) # doctest: +SKIP array([1, 2], dtype=int64)This example is valid syntax, but we were not able to check execution
>>> mi.get_locs([[True, False, True], slice('e', 'f')]) # doctest: +SKIP array([2], dtype=int64)See :
The following pages refer to to this document either explicitly or contain code examples using this.
pandas.core.indexes.multi.MultiIndex.get_slice_bound
pandas.core.indexes.multi.MultiIndex.get_loc
pandas.core.indexes.multi.MultiIndex.slice_locs
pandas.core.indexes.multi.MultiIndex.get_loc_level
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