tabsdata.tableframe.selectors.float#

float() SelectorProxy[source]#

Select all columns of float data types.

Example

>>> import tabsdata.tableframe as td_tf
>>>
>>> tf = td_tf.TableFrame({
...     "Id": [1, 2, 3, 4, 5, 6, 7, 8],
...     "Score": [91.5, 85.0, 88.5, 90.0, 87.5, 89.0, 84.0, 86.5],
...     "Name": ["A", "B", "C", "D", "E", "F", "G", "H"]
... })

Original: ┌────┬───────┬──────┐ │ Id ┆ Score ┆ Name │ │ —┆ — ┆ — │ │ i64┆ f64 ┆ str │ ╞════╪═══════╪══════╡ │ 1 ┆ 91.5 ┆ “A” │ │ 2 ┆ 85.0 ┆ “B” │ │ 3 ┆ 88.5 ┆ “C” │ │ 4 ┆ 90.0 ┆ “D” │ │ 5 ┆ 87.5 ┆ “E” │ │ 6 ┆ 89.0 ┆ “F” │ │ 7 ┆ 84.0 ┆ “G” │ │ 8 ┆ 86.5 ┆ “H” │ └────┴───────┴──────┘

>>> tf.select(td_tf.selectors.float())

Selected: ┌───────┐ │ Score │ │ — │ │ f64 │ ╞═══════╡ │ 91.5 │ │ 85.0 │ │ 88.5 │ │ 90.0 │ │ 87.5 │ │ 89.0 │ │ 84.0 │ │ 86.5 │ └───────┘