simulate_DMLM: Title simulate data for DMLMbvs model

View source: R/04_simulation.R

simulate_DMLMR Documentation

Title simulate data for DMLMbvs model

Description

Title simulate data for DMLMbvs model

Usage

simulate_DMLM(
  subject_sim = 50,
  B_sim = 50,
  n_vars = 50,
  active_cov = 10,
  rho = NULL,
  Sigma = NULL,
  seed = 111
)

Arguments

subject_sim

integer Number of subjects to simulate

B_sim

integer Number of betas

n_vars

integer Number of covariates to simulate

active_cov

integer Number of associated covariates

rho

numeric Used for covariate correlation between 0 & 1. Default is NULL. Need either rho or Sigma to be input.

Sigma

matrix A symmetric positive definite matrix used for covariate correlation structure columns must match number of covariates. Default is NULL. Need either rho or Sigma to be input.

seed

integer Seed for reproducibility, default = 555

Value

a list of outcomes:

  • Y = Y,

  • Z = Z,

  • X = X,

  • true_cov = true_cov,

  • true_coeff = true_coeff,

  • true_coeff_beta = true_coeff_beta)


Goodgolden/LDTM documentation built on May 25, 2022, 5:25 p.m.