image_output_1.png
import matplotlib.pyplot as plt

import pandas as pd

import seaborn as sns

train_df = pd.read_csv('../input/titanic/titanic_train.csv', index_col='PassengerId')

train_df.isnull().sum()

train_df = train_df.drop('Cabin', axis=1).dropna()

f, ax = plt.subplots(figsize=(25, 10))
sns.countplot(x='Age', hue='Survived', data=train_df[(train_df['Age'] > 5) & (train_df['Age'] < 30)])