Skip to content

Aggregate the columns in the DataFrame to their maximum value

Description

Aggregate the columns in the DataFrame to their maximum value

Usage

<DataFrame>$max()

Value

A polars DataFrame

Examples

library("polars")

df <- pl$DataFrame(a = 1:4, b = c(1, 2, 1, 1))
df$max()
#> shape: (1, 2)
#> ┌─────┬─────┐
#> │ a   ┆ b   │
#> │ --- ┆ --- │
#> │ i32 ┆ f64 │
#> ╞═════╪═════╡
#> │ 4   ┆ 2.0 │
#> └─────┴─────┘