coda_glmnet_longitudinal_null {coda4microbiome} | R Documentation |
coda_glmnet_longitudinal_null
Description
Performs a permutational test for the coda_glmnet_longitudinal() algorithm: It provides the distribution of results under the null hypothesis by implementing the coda_glmnet_longitudinal() on different rearrangements of the response variable.
Usage
coda_glmnet_longitudinal_null(
x,
y,
x_time,
subject_id,
ini_time,
end_time,
niter = 100,
covar = NULL,
alpha = 0.9,
lambda = "lambda.1se",
nfolds = 10,
sig = 0.05
)
Arguments
x |
abundance matrix or data frame in long format (several rows per individual) |
y |
outcome (binary); data type: numeric, character or factor vector |
x_time |
observation times |
subject_id |
subject id |
ini_time |
initial time to be analyzed |
end_time |
end time to be analyzed |
niter |
number of sample iterations |
covar |
data frame with covariates (default = NULL) |
alpha |
elastic net parameter (default = 0.9) |
lambda |
penalization parameter (default = "lambda.1se") |
nfolds |
number of folds |
sig |
significance value (default = 0.05) |
Value
list with "accuracy" and "confidence interval"
Author(s)
M. Calle - T. Susin
Examples
set.seed(123) # to reproduce the results
data(ecam_filtered, package = "coda4microbiome") # load the data
x=x_ecam # microbiome abundance
x_time = metadata$day_of_life # observation times
subject_id = metadata$studyid # subject id
y= metadata$diet # diet ("bd"= breast diet, "fd"=formula diet)
ini_time = 0
end_time = 90
coda_glmnet_longitudinal_null (x,y, x_time, subject_id, ini_time, end_time,
lambda="lambda.min",nfolds=4, niter=3)
[Package coda4microbiome version 0.2.4 Index]