DF indexing code example
Example 1: pandas df by row index
indices = [133, 22, 19, 203, 14, 1]
df_by_indices = df.iloc[indices, :]
Example 2: df.index
The index (row labels) of the DataFrame.
Example 3: indexing column in pandas
In [10]: type(titanic[["Age", "Sex"]])
Out[10]: pandas.core.frame.DataFrame