sim.tdlmm {dlmtree} | R Documentation |
Creates simulated data for TDLM & TDLMM
Description
Method for creating simulated data for TDLM & TDLMM
Usage
sim.tdlmm(
sim = "A",
n = 5000,
error = 10,
mean.p = 0.5,
prop.active = 0.05,
expList = NULL,
r = 1
)
Arguments
sim |
character (A - F) specifying simulation scenario |
n |
sample size for simulation |
error |
positive scalar specifying error variance for Gaussian response |
mean.p |
scalar between zero and one specifying mean probability for simulation scenario A |
prop.active |
proportion of active exposures for simulation scenario C |
expList |
named list of exposure data |
r |
dispersion parameter of negative binomial distribution |
Details
sim.tdlmm
Simulation scenarios:
Scenario A: Binary response with single exposure effect
Scenario B: Continuous response with main effect of PM2.5 and interaction
Scenario C: Continuous response to test exposure selection using exposure
Scenario D: Continuous response to test exposure selection using one exposure of main effect and two interaction effects among four exposures
Scenario E: Zero-inflated count response with single exposure effect
Scenario F: Zero-inflated count response with single exposure effect with main effect of PM2.5 and interaction
Value
Simulated data and true parameters
Examples
sim.tdlmm(sim = "A", mean.p = 0.5, n = 1000)