pub struct LazyFrame { /* private fields */ }Expand description
Lazy query API (LazyFrame, LazyGroupBy).
A lazily-evaluated query backed by a LogicalPlan.
Implementations§
Source§impl LazyFrame
impl LazyFrame
Sourcepub fn from_dataframe(df: DataFrame) -> Self
pub fn from_dataframe(df: DataFrame) -> Self
Create a LazyFrame that scans an in-memory DataFrame.
Sourcepub fn scan_csv(path: impl AsRef<Path>) -> Result<Self>
pub fn scan_csv(path: impl AsRef<Path>) -> Result<Self>
Build a CSV scan plan (no file I/O is performed until collect()).
Sourcepub fn scan_parquet(path: impl AsRef<Path>) -> Result<Self>
pub fn scan_parquet(path: impl AsRef<Path>) -> Result<Self>
Build a Parquet scan plan (no file I/O is performed until collect()).
Sourcepub fn select(self, exprs: Vec<Expr>) -> Self
pub fn select(self, exprs: Vec<Expr>) -> Self
Add a projection (select) node to the logical plan.
Sourcepub fn with_columns(self, exprs: Vec<Expr>) -> Self
pub fn with_columns(self, exprs: Vec<Expr>) -> Self
Add a projection (with_columns) node to the logical plan.
Sourcepub fn group_by(self, by: Vec<Expr>) -> LazyGroupBy
pub fn group_by(self, by: Vec<Expr>) -> LazyGroupBy
Start a group-by on this LazyFrame.
Sourcepub fn join<K: Into<JoinKeys>>(
self,
other: LazyFrame,
keys: K,
how: JoinType,
) -> Self
pub fn join<K: Into<JoinKeys>>( self, other: LazyFrame, keys: K, how: JoinType, ) -> Self
Join with another LazyFrame using provided join keys.
Sourcepub fn sort(self, options: SortOptions) -> Self
pub fn sort(self, options: SortOptions) -> Self
Sort by one or more columns.
Sourcepub fn fill_null<T: Into<FillNull>>(self, fill: T) -> Self
pub fn fill_null<T: Into<FillNull>>(self, fill: T) -> Self
Fill null values using a scalar or strategy.
Sourcepub fn drop_nulls(self, subset: Option<Vec<String>>) -> Self
pub fn drop_nulls(self, subset: Option<Vec<String>>) -> Self
Drop rows containing null values.
Sourcepub fn null_count(self) -> Self
pub fn null_count(self) -> Self
Count null values per column.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LazyFrame
impl !RefUnwindSafe for LazyFrame
impl Send for LazyFrame
impl Sync for LazyFrame
impl Unpin for LazyFrame
impl !UnwindSafe for LazyFrame
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more