pulls | R Documentation |
Extract the simulated effects out of a cooked simulation recipe
pull_x(object)
pull_y(object)
pull_e(object)
pull_xy(object)
pull_xye(object)
object |
an object of class |
The pull functions enable a convenient extraction of certain simulated
effects according to the desire of the user.
With pull_*
you can simply specify which effects you want to
extract out of the simulation
Returns the desired effects in a tibble.
# create a simulation
linear_sim <- Xy() %>%
add_linear(p = 5) %>%
simulate(n = 100)
# fetch the target
y <- linear_sim %>% pull_y()
# fetch all features
X <- linear_sim %>% pull_x()
# fetch the features and the target
xy <- linear_sim %>% pull_xy()
# fetch the residuals of the simulation
e <- linear_sim %>% pull_e()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.