how to use pandas to remove rows with nan code example Example: drop if nan in column pandas df = df[df['EPS'].notna()]