text_html_output_1.png
import pandas as pd

income_data = pd.read_csv('../input/adult-income-dataset/adult.csv')

income_data.isnull().sum()

income_data.isin(['?']).sum()

income_data.income = [1 if each == '>50K' else 0 for each in income_data.income]
y = income_data.income
y

dup = income_data.duplicated().any()

income_data = income_data.drop_duplicates()

income_data.drop(['fnlwgt', 'native-country'], axis=1, inplace=True)

income_data.head()