Learn R Programming

ezsim (version 0.5.5)

run.ezsim: Run the Simulation

Description

Run the Simulation of an ezsim object. The simulation result is store into the ezsim object in the argument directly, reassignment is not needed.

Usage

"run"(x, ...)

Arguments

x
An ezsim object
...
not used

Examples

Run this code
## Not run: 
# ezsim_basic<-ezsim(
#     m             = 100,
#     run           = FALSE,
#     run_test      = TRUE,
#     display_name  = c(mean_hat="hat(mu)",sd_mean_hat="hat(sigma[hat(mu)])"),
#     parameter_def = createParDef(list(n=seq(20,80,20),mu=c(0,2),sigma=c(1,3,5))),
#     dgp           = function() rnorm(n,mu,sigma),
#     estimator     = function(x) c(mean_hat = mean(x),
#                                  sd_mean_hat=sd(x)/sqrt(length(x)-1)),
#     true_value    = function() c(mu, sigma / sqrt(n-1))
# )
# run(ezsim_basic)
# ## End(Not run)

Run the code above in your browser using DataLab