WoodworkTableAccessor.drop(columns, inplace=False)[source]#

Drop specified columns from a DataFrame.

  • columns (str or list[str]) – Column name or names to drop. Must be present in the DataFrame.

  • inplace (bool) – If False, return a copy. Otherwise, do operation inplace and return None.


DataFrame with the specified columns removed, maintaining Woodwork typing information or None if inplace=True. Only possible for pandas dataframes.

Return type:

DataFrame or None


This method is used for removing columns only. To remove rows with drop, go through the DataFrame directly and then reinitialize Woodwork with DataFrame.ww.init instead of calling DataFrame.ww.drop.