fill nan with ' ' pandas code example
Example 1: how to fill nan values with mean in pandas
df.fillna(df.mean())
Example 2: represent NaN with pandas in python
import pandas as pd
if pd.isnull(float("Nan")):
print("Null Value.")
df.fillna(df.mean())
import pandas as pd
if pd.isnull(float("Nan")):
print("Null Value.")