1In [8]: age_sex = titanic[["Age", "Sex"]]
2
3In [9]: age_sex.head()
4Out[9]:
5 Age Sex
60 22.0 male
71 38.0 female
82 26.0 female
93 35.0 female
104 35.0 male
11
1In [10]: type(titanic[["Age", "Sex"]])
2Out[10]: pandas.core.frame.DataFrame
3