0
I want to create a new DataFrame
with the following condition:
marvel.loc[ marvel['Orientation'] != 'NaN' ]
I mean, I want every line that has the column 'Orientation'== 'NaN'
are deleted, but there is something going wrong. Follow the code:
marvel= pd.read_csv('Heroes_Marvel.csv')
marvel.count()
print(marvel.isna().sum())
marvel.columns
orientation= marvel.loc[(marvel['Orientation']!='NaN')]
and when I put to print the Orientation
is everything including the NaN's