pandas.MultiIndex.levshape — pandas 2.2.3 documentation (original) (raw)

property MultiIndex.levshape[source]#

A tuple with the length of each level.

Examples

mi = pd.MultiIndex.from_arrays([['a'], ['b'], ['c']]) mi MultiIndex([('a', 'b', 'c')], ) mi.levshape (1, 1, 1)