## In this example we simulate an independent sample design with skewed outcome
## Model was specified with the 'calculate_mean_matrix function' (see ?calculate_mean_matrix)
refmean <- 1
treatgroups <- 4
timepoints <- 5
treateff <- 1.25
timeeff <- 0.85
factors_levels_names <- list(treatment=letters[1:treatgroups], time=1:timepoints)
indep_matrix <- calculate_mean_matrix(refmean = refmean,
fAeffect = treateff, fBeffect = timeeff,
nlfA = treatgroups, nlfB = timepoints,
label_list = factors_levels_names)
indep_skewsim <- simulate_twoway_nrange(indep_matrix, seq(6, 12, 2),
distribution = "skewed", skewness = 1.8, nsims=5)
##used low number of iterations to reduce computation time
test_power_overkn(indep_skewsim, test="rank")
Run the code above in your browser using DataLab