tabsdata.tableframe.functions.eager.concat#

concat(items: Iterable[TdType]) TdType[source]#

Combine multiple TableFrames by stacking their rows.

Parameters:

items – The TableFrames to concatenate.

Example:

>>> import tabsdata as td
>>>
>>> tf1: td.TableFrame ...
>>>
┌──────┬──────┐
│ a    ┆ b    │
│ ---  ┆ ---  │
│ str  ┆ i64  │
╞══════╪══════╡
│ a    ┆ 1    │
│ b    ┆ 2    │
└──────┴──────┘
>>>
>>> tf2: td.TableFrame ...
>>>
┌──────┬──────┐
│ a    ┆ b    │
│ ---  ┆ ---  │
│ str  ┆ i64  │
╞══════╪══════╡
│ x    ┆ 10   │
│ y    ┆ 20   │
└──────┴──────┘
>>>
>>> tf = td.concat(tf1, tf2)
>>>
┌──────┬──────┐
│ a    ┆ b    │
│ ---  ┆ ---  │
│ str  ┆ i64  │
╞══════╪══════╡
│ a    ┆ 1    │
│ b    ┆ 2    │
│ x    ┆ 10   │
│ y    ┆ 20   │
└──────┴──────┘