application_vnd.jupyter.stderr_output_1.png
import matplotlib.pyplot as plt

import pandas as pd

import seaborn as sns

mydataset = pd.read_csv('HR_comma_sep.csv')

mydataset.shape

mydataset.dtypes

fig = plt.figure(figsize=(10,10))
corr = mydataset.corr()
sns.heatmap(corr, vmax=1, square=True,annot=True)
sns.plt.title('Correlation Matrix Heatmap')

mydataset.mean()

print('there are {} employees evaluated more than 0.7'.format(len(mydataset[mydataset['last_evaluation'] > 0.7])))
print('there are {} employees evaluated less than 0.7'.format(len(mydataset[mydataset['last_evaluation'] <= 0.7])))
print('there are {} employees satisfication level more than 0.6'.format(len(mydataset[mydataset['satisfaction_level'] > 0.6])))
print('there are {} employees satisfication level less than 0.6'.format(len(mydataset[mydataset['satisfaction_level'] <= 0.6])))
print('there are {} employees have project more than 3.80'.format(len(mydataset[mydataset['number_project'] > 3.8])))
print('there are {} employees have project less than 3.80'.format(len(mydataset[mydataset['number_project'] <= 3.8])))
print('there are {} employees that spend average monthly hours more than 201.050337'.format(len(mydataset[mydataset['average_montly_hours'] > 201.050337])))
print('there are {} employees that spend average monthly hours less than 201.050337'.format(len(mydataset[mydataset['average_montly_hours'] <= 201.050337])))