View source: R/BSkySetWeight.r
BSkySetWeight | R Documentation |
Creates a new dataset with rows expanded as per weights. Expands (replicates) the rows of a data.frame by a value contained in one of the columns in the source data.frame or data.table. BSkySetWeights() calls expandRows() from the package splitstackshape.
BSkySetWeight(weights, data, newdata)
weights |
The dataset variable that contains the weights. |
data |
The input data.frame or data.table. |
newdata |
The new dataset where the rows are replicated for the weights specified. |
expanded dataset according to the weights
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.