Learn R Programming

ALDEx3 (version 1.0.2)

aldex.mem.sim: Simulation for testing mixed effects models.

Description

Includes random intercpt, option to include random slope, second random intercept, and time-correlation.

Usage

aldex.mem.sim(
  D,
  days,
  subjects,
  depth = 10000,
  location = 1,
  random_slope = FALSE,
  corr = 0,
  rho_ar1 = 0,
  sd_resid = 0.1
)

Arguments

D

number of taxa/genes

days

num days (i.e., repeated measurements) for each subject

subjects

num of subjects to simulate

depth

sum of counts for each multinomial draw

location

second random intercept, if 0 ignore, else simulate num of locations

random_slope

If true, simulate a random slope for each subject.

corr

The correlation between slope/random intercept

rho_ar1

The ar1 time-correlation, if 0, don't simulate

sd_resid

The residual error time-correlation.

Author

Kyle McGovern