US Census Data Drop Duplicates

duplicates = us_census.State.duplicated()
us_census = us_census.drop_duplicates()

I checked the state column for duplicates and found there were.

At first I didnt use .State and it returned no duplicates so then I included .State

But when I try to drop duplicates, it doesn’t work. The df us_census is still the same including the duplicates.

Not sure what I am doing wrong here.

I tried to include .State but that would only return the State column

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.