
Expand a vector or data frame
Source:R/syncing_df_expand.R
, R/syncing_vector_expand.R
expanding_vectors_or_dataframes.Rd
Expand a vector or data frame
Arguments
- x
The vector or data frame
- newLength
The new length (or number of rows for a data frame)
- fill
When expanding streams, whether to duplicate elements to fill the resulting vector. Ignored if
fillFun
is specified.- neverFill
Columns to never fill regardless of whether fill is
TRUE
.- paddingValue
The value to insert for rows when not filling (by default, filling carries over the value from the last preceding row that had a value specified).
- expandFun
If specified, when expanding streams, instead of potentially filling the new larger vector with elements (if
fill
isTRUE
), the vectors are passed to functionexpandFun
, which must accept a vector (to compress) and a single integer (with the desired resulting length of the vector).- silent
Whether to be silent or chatty.