text_plain_output_1.png
import numpy as np

import numpy as np # linear algebra

import pandas as pd

import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)

import seaborn as sns

df = pd.read_csv('../input/engineering-graduate-salary-prediction/Engineering_graduate_salary.csv')
df

df.columns

df.isnull().sum()

df.shape

df.columns

df2 = df.drop(columns=['ID', 'DOB', '10board', '12graduation', '12board', 'CollegeState', 'CollegeID', 'CollegeCityTier', 'CollegeCityID', 'GraduationYear'])

df2 = df2.drop_duplicates()

df3 = df2[df['collegeGPA'] >= 40]
df3.shape

df3 = df3.replace(-1, np.nan)

column_with_nan = [column for column in df3.columns if df3.isnull().sum()[column] > 0]
for column in column_with_nan:
    df3[column] = df3[column].fillna(df3[column].mean())

df3.columns

df3.columns