Table Of Contents


Enter search terms or a module, class or function name.


DataFrame.filter(items=None, like=None, regex=None, axis=None)

Restrict the info axis to set of items or wildcard


items : list-like

List of info axis to restrict to (must not all be present)

like : string

Keep info axis where “arg in col == True”

regex : string (regular expression)

Keep info axis with, col) == True

axis : int or None

The axis to filter on. By default this is the info axis. The “info axis” is the axis that is used when indexing with []. For example, df = DataFrame({'a': [1, 2, 3, 4]]}); df['a']. So, the DataFrame columns are the info axis.


Arguments are mutually exclusive, but this is not checked for