text_plain_output_1.png
import matplotlib.pyplot as plt

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

import seaborn as sns  # visualization tool

happy = pd.read_csv('../input/world-happiness-report-2019.csv')

happy.corr

#correlation map
f,ax = plt.subplots(figsize=(12, 12))
sns.heatmap(happy.corr(), annot=True, linewidths=.5, fmt= '.1f',ax=ax)
#plt.show()

happy.columns

happy.columns = [each.split()[0] + '_' + each.split()[1] if len(each.split()) > 1 else each for each in happy.columns]
happy.columns

plt.clf()

dictionary = {'spain': 'madrid', 'usa': 'vegas'}

dictionary['spain'] = 'barcelona'
dictionary['france'] = 'paris'
del dictionary['spain']
dictionary.clear()

happy = pd.read_csv('../input/world-happiness-report-2019.csv')

i = 0
while i != 5:
    i += 1

lis = [1, 2, 3, 4, 5]
for i in lis:
    print('i is: ', i)
print('')
for index, value in enumerate(lis):
    print(index, ' : ', value)
print('')
dictionary = {'spain': 'madrid', 'france': 'paris'}
for key, value in dictionary.items():
    print(key, ' : ', value)
print('')
for index, value in happy[['Corruption']][0:1].iterrows():
    print(index, ' : ', value)