Is there a reset_index equivalent for the column headings? In other words, if the column names are an MultiIndex, how would I drop one of the levels?
Comment From: jtratner
In the future, probably better to ask these kind of questions on StackOverflow - broader audience there and ends up being more accessible to more people. (Plus, better to have GH generally for bug reports).
Comment From: jtratner
(hit the wrong button there)
Comment From: rhshadrach
If I'm understanding this, I think the following suffices:
df = pd.DataFrame([1, 2, 3], columns=pd.MultiIndex.from_tuples([(1, 2)]))
df.columns = df.columns.droplevel(0)
Comment From: MarcoGorelli
closing as the above seems like the correct solution
Comment From: MarcoGorelli
but please ping if you disagree / have an example with desired output