-
-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Closed
Labels
IndexingRelated to indexing on series/frames, not to indexes themselvesRelated to indexing on series/frames, not to indexes themselvesMultiIndex
Milestone
Description
In [1]: import pandas as pd
In [2]: pd.MultiIndex.from_tuples([('a',), ('b',)])
Out[2]: Index(['a', 'b'], dtype='object')
This should return a MultiIndex
I think, like
Out[5]:
MultiIndex(levels=[['a', 'b']],
labels=[[0, 1]])
Well, pd.MultiIndex([['a', 'b']], [[0, 1]])
returns the same thing as from_tuples
(an index) so maybe this is intentional.
Trying to figure out if this is intentional or not (this came up in my categorical dtype refactor).
Metadata
Metadata
Assignees
Labels
IndexingRelated to indexing on series/frames, not to indexes themselvesRelated to indexing on series/frames, not to indexes themselvesMultiIndex