text_plain_output_1.png
import matplotlib.pyplot as plt

import matplotlib.style as style

import numpy as np

import pandas as pd

import seaborn as sns

Sample = pd.read_csv('/kaggle/input/home-data-for-ml-course/train.csv', index_col='Id')
Test = pd.read_csv('/kaggle/input/home-data-for-ml-course/test.csv', index_col='Id')

Sample.shape

Tgt_Col = 'SalePrice'
Num_Col = Sample.select_dtypes(exclude='object').drop(Tgt_Col, axis=1).columns
Cat_Col = Sample.select_dtypes(include='object').columns

plt.ticklabel_format(style='plain', axis='y')

plt.ticklabel_format(style='plain', axis='y')

fig = plt.figure(figsize=(12,18))
for idx,col in enumerate(Num_Col):
    fig.add_subplot(9,4,idx+1)
    sns.distplot(Sample[col].dropna(), kde_kws={'bw':0.1})
    plt.xlabel(col)
plt.tight_layout()
plt.show()

cor = Sample.corr()
import matplotlib.style as style
style.use('ggplot')
sns.set_style('whitegrid')
mask = np.zeros_like(cor, dtype=np.bool)
mask[np.triu_indices_from(mask)] = True

for col in Sample[Cat_Col]:
    if Sample[col].isnull().sum() > 0:
        print(col, ' : ', Sample[col].isnull().sum(), Sample[col].unique())