tabsdata.tableframe.functions.col
TdCol | This class is used to create TableFrame column expressions. |
TdCol
classView source ↗
class TdCol(*args, **kwargs)
This class is used to create TableFrame column expressions.
An instance of this class is available as col. It can be called like a function
(e.g., td.col("name")).
For more information, refer to the __call__ method documentation.
This helper class provides an alternative way to create column expressions using
attribute lookup.
For instance, col.name is equivalent to col("name"). Refer to
:func:__getattr__ method.
Example:
>>> import tabsdata as td
>>>
>>> tf: td.TableFrame ...
>>>
>>> tf = tf.with_columns(full_name=(td.col("last_name") + ", " + >>> td.col("first_name"))