View source: R/PomaOddsRatio.R
PomaOddsRatio | R Documentation |
PomaOddsRatio
calculates the Odds Ratios for each feature from a logistic regression model using the binary outcome (group/type must be a binary factor) as a dependent variable.
PomaOddsRatio(data, feature_name = NULL, covs = NULL, show_ci = TRUE)
data |
A |
feature_name |
Character vector. Indicates the name/s of feature/s that will be used to fit the model. If it's NULL (default), all variables will be included in the model. |
covs |
Character vector. Indicates the names of |
show_ci |
Logical. Indicates if the 95% confidence intervals will be plotted. Default is |
A list
with results including plots and tables.
Pol Castellano-Escuder
data <- POMA::st000336 %>% # Example SummarizedExperiment object included in POMA
PomaImpute() %>%
PomaNorm()
## Output is a list with objects `odds_ratio_table` (tibble) and `odds_ratio_plot` (ggplot2 object)
data %>%
PomaOddsRatio(feature_name = c("glutamic_acid", "glutamine", "glycine", "histidine"),
covs = NULL,
show_ci = TRUE)
# With covariates
data %>%
PomaOddsRatio(feature_name = c("glutamic_acid", "glutamine", "glycine", "histidine"),
covs = "steroids",
show_ci = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.