You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can see that in resulting sum_df there are duplicate rows like ('85', nan). This behavior is incorrect. combine_first() method should join such rows
The text was updated successfully, but these errors were encountered:
df.set_index(['a', 'b']) will return you empty dataframe. with index values as values of a and b and since index is a tuple. (85,nan) of first df and (85, nan) of second index are different. Hence the data is duplicated.
phofl
added
Reshaping
Concat, Merge/Join, Stack/Unstack, Explode
and removed
Needs Triage
Issue that has not been reviewed by a pandas team member
labels
Nov 1, 2020
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of pandas.
(optional) I have confirmed this bug exists on the master branch of pandas.
Code Sample, a copy-pastable example
Problem description
You can see that in resulting
sum_df
there are duplicate rows like ('85', nan). This behavior is incorrect. combine_first() method should join such rowsThe text was updated successfully, but these errors were encountered: