pandas dataframe create missing rows by nan values code example Example: pandas get rows with missing data null_data = df[df.isnull().any(axis=1)]