Simulate data from design (internal)

sim_data(
  design,
  empirical = FALSE,
  long = FALSE,
  rep = 1,
  nested = TRUE,
  seed = NULL
)

Arguments

design

A list of design parameters created by check_design()

empirical

logical. If true, mu, sd and r specify the empirical not population mean, sd and covariance

long

Whether the returned tbl is in wide (default = FALSE) or long (TRUE) format

rep

the number of data frames to return (default 1); if greater than 1, the returned data frame is nested by rep

nested

Whether to nest data frames by rep if rep > 1

seed

DEPRECATED use set.seed() instead before running this function

Value

a tbl