Project us census
I am stuck at 10th checkpoint in this project where i can’t run duplicate() method on my dataframe or my list, it is showing error.
Please can anyone help me?
Thanks in Advance :blush:

Hi, what’s the error you receive?

Did you do this first?

" print(census.duplicated())
AttributeError: ‘list’ object has no attribute ‘duplicated’ "

Yes I did try that, I am getting the above error, I might have made some mistake in the code.

It might be helpful to go back and review “Dealing with Duplicates” in the lesson here:

.duplicated() method documentation also here:

Also, the .drop_duplicates() method is used on the df. But, you have to create a new df.
Like so: new_df = old_df.drop_duplicates()

1 Like