sort

Tables.sort(by: Optional[str] = None, key: Optional[Callable[[Table], Any]] = None, descending: Optional[bool] = None) Tables[source]

Sorts the Tables container. If no arguments are provided the container is sorted by target and name.

Args:
by (str, optional):
The name of field to sort by. Possible fields:
  • name(s)

  • importances(s)

key (callable, optional):

A callable that evaluates to a sort key for a given item.

descending (bool, optional):

Whether to sort in descending order.

Return:
getml.pipeline.Tables:

A container of sorted tables.

Example:
by_importance = my_pipeline.tables.sort(key=lambda table: table.importance)