We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Assigning a value (scalar or Series) to the subset of a dataframe with MultiIndex columns addressed by a partial label doesn't work.
df = pandas.DataFrame(index=[1, 3, 5], columns=pandas.MultiIndex.from_tuples([('A', '1'), ('A', '2'), ('B', '1')])) df['A'] = 0.0 # Doesn't work df['A'] = df['B', '1'] # Works, but adds a column instead of updating the two existing ones df2 = df.T.copy() df2.ix['A'] = 0.0 # Works df2.ix['A'] = df2['B', '1'] # Works
The same thing in the rows dimension works as expected.
The text was updated successfully, but these errors were encountered:
6abbbc1
No branches or pull requests
Assigning a value (scalar or Series) to the subset of a dataframe with MultiIndex columns addressed by a partial label doesn't work.
The same thing in the rows dimension works as expected.
The text was updated successfully, but these errors were encountered: