import math value = math.nan math.isnan(value) ## Returns True value = 45.45 math.isnan(value) ## Returns False
import pandas as pd pd.isnull(df.columnName).sum() pd.notnull(df.columnName).sum()