pandas 0.7.3 documentation

pandas.DataFrame.xs

DataFrame.xs(key, axis=0, level=None, copy=True)

Returns a cross-section (row or column) from the DataFrame as a Series object. Defaults to returning a row (axis 0)

Parameters :

key : object

Some label contained in the index, or partially in a MultiIndex

axis : int, default 0

Axis to retrieve cross-section on

copy : boolean, default True

Whether to make a copy of the data

Returns :

xs : Series