Functions#
These functions are available from the Polars module root and can be used as expressions, and sometimes also in eager contexts.
Available in module namespace:
|
Either return an expression representing all columns, or evaluate a bitwise AND operation. |
|
Compute the bitwise AND horizontally across columns. |
|
Evaluate a bitwise OR operation. |
|
Compute the bitwise OR horizontally across columns. |
|
Approximate count of unique values. |
|
Generate a range of integers. |
|
Compute two argument arctan in radians. |
|
Compute two argument arctan in degrees. |
|
Return the row indices that would sort the column(s). |
|
Return indices where |
|
Count the number of business days between |
|
Folds the columns from left to right, keeping the first non-null value. |
|
Horizontally concatenate columns into a single array column. |
|
Horizontally concatenate columns into a single list column. |
|
Horizontally concatenate columns into a single string column. |
|
Compute the Pearson's or Spearman rank correlation correlation between two columns. |
|
Return the number of non-null values in the column. |
|
Compute the covariance between two columns/ expressions. |
|
Return the cumulative count of the non-null values in the column. |
|
Cumulatively fold horizontally across columns with a left fold. |
|
Cumulatively reduce horizontally across columns with a left fold. |
|
Cumulatively sum all values. |
|
Cumulatively sum all values horizontally across columns. |
|
Create a Polars literal expression of type Date. |
|
Generate a date range. |
|
Create a column of date ranges. |
|
Create a Polars literal expression of type Datetime. |
|
Generate a datetime range. |
|
Create a column of datetime ranges. |
|
Create polars |
|
Alias for an element being evaluated in an |
|
Represent all columns except for the given columns. |
|
Get the first column or value. |
|
Accumulate over multiple columns horizontally/ row wise with a left fold. |
|
Format expressions as a string. |
|
Utility function that parses an epoch timestamp (or Unix time) to Polars Date(time). |
|
Syntactic sugar for |
|
Get the first |
|
Aggregate all column values into a list. |
|
Generate a range of integers. |
|
Generate a range of integers for each row of the input columns. |
|
Get the last column or value. |
|
Return the number of rows in the context. |
|
Return an expression representing a literal value. |
|
Map a custom function over multiple columns/expressions. |
|
Apply a custom/user-defined function (UDF) in a GroupBy context. |
|
Get the maximum value. |
|
Get the maximum value horizontally across columns. |
|
Get the mean value. |
|
Compute the mean of all values horizontally across columns. |
|
Get the median value. |
|
Get the minimum value. |
|
Get the minimum value horizontally across columns. |
|
Count unique values. |
|
Get the nth column(s) of the context. |
|
Construct a column of length |
|
Syntactic sugar for |
|
Accumulate over multiple columns horizontally/ row wise with a left fold. |
|
Construct a column of length |
|
Compute the rolling correlation between two columns/ expressions. |
|
Compute the rolling covariance between two columns/ expressions. |
|
Run polars expressions without a context. |
|
Execute a SQL query against frames in the global namespace. |
|
Parse one or more SQL expressions to Polars expression(s). |
|
Get the standard deviation. |
|
Collect columns into a struct column. |
|
Sum all values. |
|
Sum all values horizontally across columns. |
|
Get the last |
|
Create a Polars literal expression of type Time. |
|
Generate a time range. |
|
Create a column of time ranges. |
|
Get the variance. |
|
Start a |
|
Construct a column of length |
Available in expression namespace:
|
Return whether all values in the column are |
|
Return whether any of the values in the column are |
Approximate count of unique values. |
|
Return the number of non-null elements in the column. |
|
Get the first value. |
|
|
Get the first |
Aggregate values into a list. |
|
|
Apply a custom python function to a whole Series or sequence of Series. |
|
Map a custom/user-defined function (UDF) to each element of a column. |
|
Get maximum value. |
Get mean value. |
|
Get median value using linear interpolation. |
|
|
Get minimum value. |
Count unique values. |
|
|
Get quantile value. |
|
Get standard deviation. |
|
Get sum value. |
|
Get the last |
|
Get variance. |