PomaPCR | R Documentation |
PomaPCR
performs Principal Components Regression.
PomaPCR(data, center = TRUE, scale = TRUE, ncomp = 2, y = NULL, adjust = "fdr")
data |
A |
center |
Logical. Indicates whether the variables should be shifted to be zero centered. Default is TRUE. |
scale |
Logical. Indicates whether the variables should be scaled to have unit variance before the analysis takes place. Default is TRUE. |
ncomp |
Numeric. Indicates the number of principal components used as predictors in the model. Default is 2. |
y |
Character. Indicates the name of |
adjust |
Character. Multiple comparisons correction method to adjust p-values. Available options are: "fdr" (false discovery rate), "holm", "hochberg", "hommel", "bonferroni", "BH" (Benjamini-Hochberg), and "BY" (Benjamini-Yekutieli). |
A tibble
with the results.
Pol Castellano-Escuder
data <- POMA::st000284 %>% # Example SummarizedExperiment object included in POMA
PomaNorm()
# PCR with 2 components and the default outcome (1st column of `colData`)
data %>%
PomaPCR(center = TRUE,
scale = TRUE,
ncomp = 2,
y = NULL,
adjust = "fdr")
# PCR with 2 components and alternative outcome
data %>%
PomaPCR(center = TRUE,
scale = TRUE,
ncomp = 2,
y = "age_at_consent",
adjust = "fdr")
# PCR with 20 components and alternative outcome
data %>%
PomaPCR(center = TRUE,
scale = TRUE,
ncomp = 20,
y = "age_at_consent",
adjust = "fdr")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.