iCARH.model {iCARH} | R Documentation |
Runs the integrative CAR Horseshoe model
Description
Infers treatment effects, association with heterogeneous omic variables, pathway perturbation among other parameters (e.g. time dependence). Regression coefficients (beta parameter) are initialized using a univariate regression ignoring time and metabolite dependence.
Usage
iCARH.model(
X,
Y = NULL,
drug,
groups = NULL,
pathways,
tau = 1.2,
NA_value = -99999,
init = T,
...
)
Arguments
X |
the metabolomics time-course data with dimensions timepoints x observations x variables |
Y |
the additional omic time-course data with dimensions timepoints x observations x variables |
drug |
treatment effect. Could be either continuous (an administered drug or other external factor) or
binary (cases vs controls). In the binary case the |
groups |
grouping vector (binary). Use when |
pathways |
pathway adjacency matrices as returned by iCARH.getPathwaysMat |
tau |
global sparsity parameter |
NA_value |
NA values are incompatible with stan. This is a wrapper to encode missing values in |
init |
If |
... |
additional stan parameters |
Value
stan object
Examples
data.sim = iCARH.simulate(4, 8, 10, 2, 2, path.probs=0.3, Zgroupeff=c(0,4),
beta.val=c(1,-1,0.5, -0.5))
XX = data.sim$XX
Y = data.sim$Y
Z = data.sim$Z
pathways = data.sim$pathways
rstan_options(auto_write = TRUE)
options(mc.cores = 2)
fit = iCARH.model(XX, Y, Z,groups=rep(c(0,1), each=4), pathways,
control = list(adapt_delta = 0.99, max_treedepth=10), iter = 2, chains = 2)