Python in Hydrology and Hydraulics
Python programming, with examples in hydraulic engineering and in hydrology.
Monday, October 21, 2019
Delete row/ column in DataFrame with Null/ NaN values
if df0 is a Pandas DataFrame with null Values:
df0=df0.dropna(axis=0,how='all') - will remove rows that have only 'NaN' values
df0=df0.dropna(axis=1,how='all') - will remove columns that have only 'NaN' values
Newer Posts
Older Posts
Home
Subscribe to:
Posts (Atom)