polars_plan::dsl

Module functions

Source
Expand description

§Functions

Functions on expressions that might be useful.

Structs§

DatetimeArgstemporal
Arguments used by datetime in order to produce an Expr of Datetime
DurationArgstemporal
Arguments used by duration in order to produce an Expr of Duration

Functions§

all
Selects all columns. Shorthand for col("*").
all_horizontal
Create a new column with the bitwise-and of the elements in each row.
any_horizontal
Create a new column with the bitwise-or of the elements in each row.
apply_binary
Like map_binary, but used in a group_by-aggregation context.
arangerange
Generate a range of integers.
arg_sort_by(range or arg_where) and range
Find the indexes that would sort these series in order of appearance.
arg_where(range or arg_where) and arg_where
Get the indices where condition evaluates true.
as_structdtype-struct
Take several expressions and collect them into a StructChunked.
avg
Find the mean of all the values in the column named name. Alias for mean.
business_day_countbusiness and dtype-date
cast
Casts the column given by Expr to a different type.
coalesce
Folds the expressions from left to right keeping the first non-null values.
col
Create a Column Expression based on a column name.
cols
Select multiple columns by name.
concat_arr
Horizontally concatenate columns into a single array-type column.
concat_expr
concat_list
Concat lists entries.
concat_strconcat_str and strings
Horizontally concat string columns in linear time
covcov
Compute the covariance between two columns.
cum_fold_exprsdtype-struct
Accumulate over multiple columns horizontally / row wise.
cum_reduce_exprsdtype-struct
Accumulate over multiple columns horizontally / row wise.
date_rangerange and temporal
Create a date range from a start and stop expression.
date_rangesrange and temporal
Create a column of date ranges from a start and stop expression.
datetimetemporal
Construct a column of Datetime from the provided DatetimeArgs.
datetime_rangerange and dtype-datetime
Create a datetime range from a start and stop expression.
datetime_rangesrange and dtype-datetime
Create a column of datetime ranges from a start and stop expression.
dtype_col
Select multiple columns by dtype.
dtype_cols
Select multiple columns by dtype.
durationtemporal
Construct a column of Duration from the provided DurationArgs
fold_exprs
Accumulate over multiple columns horizontally / row wise.
format_strconcat_str and strings
Format the results of an array of expressions using a format string
index_cols
Select multiple columns by index.
int_rangerange
Generate a range of integers.
int_rangesrange
Generate a range of integers for each row of the input columns.
is_not_null
A column which is false wherever expr is null, true elsewhere.
is_null
A column which is true wherever expr is null, false elsewhere.
linear_spacerange
Generate a series of equally-spaced points.
map_binary
Apply a closure on the two columns that are evaluated from Expr a and Expr b.
max
Find the maximum of all the values in the column named name. Shorthand for col(name).max().
max_horizontal
Create a new column with the maximum value per row.
mean
Find the mean of all the values in the column named name. Shorthand for col(name).mean().
mean_horizontal
Compute the mean of all values horizontally across columns.
median
Find the median of all the values in the column named name. Shorthand for col(name).median().
min
Find the minimum of all the values in the column named name. Shorthand for col(name).min().
min_horizontal
Create a new column with the minimum value per row.
not
Negates a boolean column.
pearson_corrcov
Compute the pearson correlation between two columns.
quantile
Find a specific quantile of all the values in the column named name.
reduce_exprs
Analogous to Iterator::reduce.
repeat
Create a column of length n containing n copies of the literal value.
rolling_corrrolling_window and cov
rolling_covrolling_window and cov
spearman_rank_corrrank and propagate_nans and cov
Compute the spearman rank correlation between two columns. Missing data will be excluded from the computation.
sum
Sum all the values in the column named name. Shorthand for col(name).sum().
sum_horizontal
Sum all values horizontally across columns.
time_rangerange and dtype-time
Generate a time range.
time_rangesrange and dtype-time
Create a column of time ranges from a start and stop expression.