sdf_bind {sparklyr} | R Documentation |
Bind multiple Spark DataFrames by row and column
Description
sdf_bind_rows()
and sdf_bind_cols()
are implementation of the common pattern of
do.call(rbind, sdfs)
or do.call(cbind, sdfs)
for binding many
Spark DataFrames into one.
Usage
sdf_bind_rows(..., id = NULL)
sdf_bind_cols(...)
Arguments
... |
Spark tbls to combine. Each argument can either be a Spark DataFrame or a list of Spark DataFrames When row-binding, columns are matched by name, and any missing columns with be filled with NA. When column-binding, rows are matched by position, so all data frames must have the same number of rows. |
id |
Data frame identifier. When |
Details
The output of sdf_bind_rows()
will contain a column if that column
appears in any of the inputs.
Value
sdf_bind_rows()
and sdf_bind_cols()
return tbl_spark