Enum polars::prelude::LogicalPlan
source · [−]pub enum LogicalPlan {
Show 19 variants
Selection {
input: Box<LogicalPlan, Global>,
predicate: Expr,
},
Cache {
input: Box<LogicalPlan, Global>,
},
CsvScan {
path: PathBuf,
schema: Arc<Schema>,
options: CsvParserOptions,
predicate: Option<Expr>,
aggregate: Vec<Expr, Global>,
},
ParquetScan {
path: PathBuf,
schema: Arc<Schema>,
predicate: Option<Expr>,
aggregate: Vec<Expr, Global>,
options: ParquetOptions,
},
IpcScan {
path: PathBuf,
schema: Arc<Schema>,
options: IpcScanOptions,
predicate: Option<Expr>,
aggregate: Vec<Expr, Global>,
},
DataFrameScan {
df: Arc<DataFrame>,
schema: Arc<Schema>,
projection: Option<Vec<Expr, Global>>,
selection: Option<Expr>,
},
LocalProjection {
expr: Vec<Expr, Global>,
input: Box<LogicalPlan, Global>,
schema: Arc<Schema>,
},
Projection {
expr: Vec<Expr, Global>,
input: Box<LogicalPlan, Global>,
schema: Arc<Schema>,
},
Aggregate {
input: Box<LogicalPlan, Global>,
keys: Arc<Vec<Expr, Global>>,
aggs: Vec<Expr, Global>,
schema: Arc<Schema>,
apply: Option<Arc<dyn DataFrameUdf + 'static>>,
maintain_order: bool,
options: GroupbyOptions,
},
Join {
input_left: Box<LogicalPlan, Global>,
input_right: Box<LogicalPlan, Global>,
schema: Arc<Schema>,
left_on: Vec<Expr, Global>,
right_on: Vec<Expr, Global>,
options: JoinOptions,
},
HStack {
input: Box<LogicalPlan, Global>,
exprs: Vec<Expr, Global>,
schema: Arc<Schema>,
},
Distinct {
input: Box<LogicalPlan, Global>,
options: DistinctOptions,
},
Sort {
input: Box<LogicalPlan, Global>,
by_column: Vec<Expr, Global>,
args: SortArguments,
},
Explode {
input: Box<LogicalPlan, Global>,
columns: Vec<String, Global>,
},
Slice {
input: Box<LogicalPlan, Global>,
offset: i64,
len: u32,
},
Melt {
input: Box<LogicalPlan, Global>,
id_vars: Arc<Vec<String, Global>>,
value_vars: Arc<Vec<String, Global>>,
schema: Arc<Schema>,
},
Udf {
input: Box<LogicalPlan, Global>,
function: Arc<dyn DataFrameUdf + 'static>,
options: LogicalPlanUdfOptions,
schema: Option<Arc<Schema>>,
},
Union {
inputs: Vec<LogicalPlan, Global>,
options: UnionOptions,
},
Error {
input: Box<LogicalPlan, Global>,
err: Arc<Mutex<RawMutex, Option<PolarsError>>>,
},
}
Variants
Selection
Filter on a boolean mask
Cache
Fields
input: Box<LogicalPlan, Global>
Cache the input at this point in the LP
CsvScan
Scan a CSV file
ParquetScan
This is supported on crate feature
parquet
only.Scan a Parquet file
IpcScan
This is supported on crate feature
ipc
only.DataFrameScan
Fields
In memory DataFrame
LocalProjection
Projection
Column selection
Aggregate
Groupby aggregation
Join
Join operation
HStack
Adding columns to the table without a Join
Distinct
Remove duplicates from the table
Sort
Sort the table
Explode
An explode operation
Slice
Slice the table
Melt
Fields
input: Box<LogicalPlan, Global>
A Melt operation
Udf
Fields
input: Box<LogicalPlan, Global>
function: Arc<dyn DataFrameUdf + 'static>
options: LogicalPlanUdfOptions
A User Defined Function
Union
Error
Catches errors and throws them later
Implementations
sourceimpl LogicalPlan
impl LogicalPlan
Trait Implementations
sourceimpl Clone for LogicalPlan
impl Clone for LogicalPlan
sourcefn clone(&self) -> LogicalPlan
fn clone(&self) -> LogicalPlan
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for LogicalPlan
impl Debug for LogicalPlan
sourceimpl Default for LogicalPlan
impl Default for LogicalPlan
sourcefn default() -> LogicalPlan
fn default() -> LogicalPlan
Returns the “default value” for a type. Read more
sourceimpl From<LogicalPlan> for LazyFrame
impl From<LogicalPlan> for LazyFrame
sourcefn from(plan: LogicalPlan) -> LazyFrame
fn from(plan: LogicalPlan) -> LazyFrame
Performs the conversion.
Auto Trait Implementations
impl !RefUnwindSafe for LogicalPlan
impl Send for LogicalPlan
impl Sync for LogicalPlan
impl Unpin for LogicalPlan
impl !UnwindSafe for LogicalPlan
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more