we all know the famous question: How to drop rows of Pandas DataFrame whose value in a certain column is NaN
But how can I select the rows in a pandas dataframe df
, where at least one column is NaN. So that:
df
columnA columnB
0 NaN 1
1 1 2
2 NaN NaN
3 1 NaN
will lead to:
df
columnA columnB
0 NaN 1
2 NaN NaN
3 1 NaN