larray.AxisCollection.translate_full_key¶
-
AxisCollection.translate_full_key(key)[source]¶ Translates a label-based key to a positional key.
Parameters: key : tuple
A full label-based key. All dimensions must be present and in the correct order.
Returns: tuple
A full positional key.
See also
Axis.translateExamples
>>> age = Axis(range(20), 'age') >>> sex = Axis('sex=M,F') >>> time = Axis([2007, 2008, 2009, 2010], 'time') >>> AxisCollection([age,sex,time]).translate_full_key((':', 'F', 2009)) (slice(None, None, None), 1, 2)