▚DATAJIN

Titanic passengers dataset

Passengers of the RMS Titanic with survival (0/1), class, sex, age, fare and port of embarkation. The classic dataset for logistic regression and chi-square tests.

Open in DATAJINDownload CSV

891 rows · 15 columns · CSV · one of the example datasets distributed with the seaborn Python library.

Columns

This is a wide dataset; the first 10 of 15 columns are listed.

ColumnType
survivednumeric
pclassnumeric
sextext
agenumeric
sibspnumeric
parchnumeric
farenumeric
embarkedtext
classtext
whotext

Summary statistics

Computed from all 891 rows. For numeric columns: mean, standard deviation and range; for text columns: the most common values.

Numeric columnMeanSDMinMedianMaxMissing
survived0.38380.48660010
pclass2.3090.83611330
age29.714.530.422880177
sibsp0.5231.1030080
parch0.38160.80610060
fare32.249.69014.45512.30
Text columnDistinct valuesMost commonMissing
sex2male (577), female (314)0
embarked3S (644), C (168), Q (77)2
class3Third (491), First (216), Second (184)0
who3man (537), woman (271), child (83)0
adult_male2True (537), False (354)0
deck7C (59), B (47), D (33), E (32)688
embark_town3Southampton (644), Cherbourg (168), Queenstown (77)2
alive2no (549), yes (342)0

Preview (first 8 rows)

survivedpclasssexagesibspparchfareembarkedclasswho
03male22.0107.25SThirdman
11female38.01071.2833CFirstwoman
13female26.0007.925SThirdwoman
11female35.01053.1SFirstwoman
03male35.0008.05SThirdman
03male008.4583QThirdman
01male54.00051.8625SFirstman
03male2.03121.075SThirdchild

Analyses to try

Logistic regression calculator (binary outcome)Predict a 0/1 outcome; coefficients and odds ratios.ROC curve and AUC calculatorAUC with 95% CI and the best cut-off threshold.

All example datasets