text_html_output_1.png
import matplotlib.pyplot as plt

import pandas as pd

import seaborn as sns

suicide_df = pd.read_csv('../input/master.csv')

suicide_df.isnull().any()

suicide_df = suicide_df.drop(['HDI for year', 'country-year', 'gdp_per_capita ($)'], axis=1)

min_year = min(suicide_df.year)
max_year = max(suicide_df.year)

df = suicide_df[['country', 'suicides_no']]

df1 = df.groupby('country').sum()

df1 = df1.sort_values(by='suicides_no', ascending=False).reset_index()
df1 = df1.loc[df1['suicides_no'] > 1000]

plt.figure(figsize=(10, 6))
sns.countplot(x='generation', hue='sex', data=suicide_df)