syncing_df_compress {rock} | R Documentation |
Compress a vector or data frame
Description
Compress a vector or data frame
Usage
syncing_df_compress(
x,
newLength,
sep = " ",
compressFun = NULL,
compressFunPart = NULL,
silent = rock::opts$get("silent")
)
syncing_vector_compress(
x,
newLength,
sep = " ",
compressFun = NULL,
compressFunPart = NULL,
silent = rock::opts$get("silent")
)
Arguments
x |
The vector or data frame |
newLength |
The new length (or number of rows for a data frame) |
sep |
When not specifying |
compressFun |
If specified, when compressing streams, instead of pasting
elements together using separator |
compressFunPart |
A function to apply to the segments that are
automatically created; this can be passed instead of |
silent |
Whether to be silent or chatty. |
Value
The compressed vector or data frame
Examples
rock::syncing_vector_compress(
1:10,
3
);
rock::syncing_df_compress(
mtcars[, 1:4],
6
);
rock::syncing_df_compress(
mtcars[, 1:4],
6,
compressFunPart = mean
);
[Package rock version 0.8.1 Index]