towhee.datacollection.mixins.display.to_plain_table

towhee.datacollection.mixins.display.to_plain_table(data, header, tablefmt)[source]

Convert two dimensional data structure into plain table

Parameters:
  • data (List[List] or List[Dict]) – The data filled into table. If a list of dict is given, keys are used as column names.

  • header (Iterable[str]) – The names of columns defined by user.

  • tablefmt (str) – The format of the output, supports plain, grid.

Returns:

The table in plain format.

Return type:

str