split-methods | R Documentation |
Similar to base::split, but working along the 6th, iter, dimension of any singular FLR object. The object is divided into as many objects as unique values in f, and returned as an FLlst-derived object, e.g. an FLQuants object when applied to an FLQuant.
## S4 method for signature 'FLQuant,vector'
split(x, f)
## S4 method for signature 'FLComp,vector'
split(x, f)
x |
The object to be split. |
f |
The vector of group names. |
An object of the corresponding plural class (FLQuants from FLQuant).
Iago Mosqueira (WMR).
# FROM FLQuant to FLQuants
flq <- rlnorm(20, FLQuant(seq(0.1, 0.8, length=10)), 0.2)
split(flq, c(rep(1, 5), rep(2,15)))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.