perform_logistic: Logistic regression

Description Usage Arguments Details Value See Also Examples

View source: R/stats.R

Description

Fits a logistic regression model separately for each feature. Returns all relevant statistics.

Usage

1
2
perform_logistic(object, formula_char, all_features = FALSE,
  ci_level = 0.95, ...)

Arguments

object

a MetaboSet object

formula_char

character, the formula to be used in the linear model (see Details)

all_features

should all features be included in FDR correction?

ci_level

the confidence level used in constructing the confidence intervals for regression coefficients

...

additional parameters passed to glm

Details

The logistic regression model is fit on combined_data(object). Thus, column names in pData(object) can be specified. To make the formulas flexible, the word "Feature" must be used to signal the role of the features in the formula. "Feature" will be replaced by the actual Feature IDs during model fitting, see the example

Value

a data frame with one row per feature, with all the relevant statistics of the linear model as columns

See Also

glm

Examples

1
2
3
# A simple example without QC samples
# Time predicted by features
logistic_results <- perform_logistic(drop_qcs(example_set), formula_char = "Time ~ Feature + Group ")

antonvsdata/amp documentation built on Jan. 8, 2020, 3:15 a.m.