VISUALIZATION — LEARNING FROM DISASTER: TITANIC

Loquarts
Towards Data Science
3 min readDec 9, 2016

--

I have recently been learning about data analysis and my journey took me to the kaggle exercise on “Learning from disaster: Titanic”. I was also inspired to do some visual analysis of the dataset from some other resources I came across.

The dataset gives information about the details of the passengers aboard the titanic and a column on survival of the passengers. Those who survived are represented as “1” while those who did not survive are represented as “0”. The goal of this exercise is to determine if with the other features/information about the passengers it is possible to determine those who are likely to survive.

N.B: The terms column, feature and information all have the same meaning here and can be used interchangeably.

I would take some features/columns and visualize it to gain insight into the dataset and determine if some certain features are likely to determine if a passenger would survive or not.

First, the dataset is cleaned up to remove or replace missing values. The columns in the dataset are;
PassengerId: Passenger Identity
Survived: Whether passenger survived or not
Pclass: Class of ticket
Name: Name of passenger
Sex: Sex of passenger (Male or Female)
Age: Age of passenger
SibSp: Number of sibling and/or spouse travelling with passenger
Parch: Number of parent and/or children travelling with passenger
Ticket: Ticket number
Fare: Price of ticket
Cabin: Cabin number

SEX OF PASSENGERS

More females survive than males.

AGE

CLASS OF TICKET(Pclass)

The first graph shows us that Pclass 1 on the average is more expensive while Pclass 3 is the least expensive, and the second graph shows that passengers with Pclass 1 tickets are more likely to survive and Pclass 3 ticket holders are less likely to survive.

PORT EMBARKED

The first graph shows that Port C is on the average more expensive that the other ports. The second graph shows that those who embarked at port C have a little more likely chance at survival.

Our last two sections have shown us that those who paid more for the trip are more likely to survive.

FAMILY MEMBERS

I’ve added the Sibling/Spouse column with the Parent/Children column to make a Family column. We would now use this Family column to visualize if passengers with family aboard are likely to survive or not.

SUMMARY: A female who paid for a Pclass 1 ticket and embarked at Port C with one to three family members aboard and is less than 10 years of age is more likely to survive.

--

--