#find and replace median for each NaN values columns python code example Example: pandas to convert null values to mean in numeric column df.fillna(df.mean(), inplace=True)