glm_regular: Build and visualize a generalized linear model.

Description Usage Arguments Details

View source: R/glm_regular.R

Description

glm_regular is a function used to build a regular generalized linear model based on genomic features.

Usage

1
2
3
glm_regular(Y, PREDICTORS, HDER = "glm", family = c("gaussian",
  "binomial", "poisson"), CUT_OFF = 5, Critical_value = 0.05,
  Exclude_intercept = F, Sort_by = c("byZstat", "byLogit"))

Arguments

Y

A vector that defines the response variable. It can be a 2-column integer matrix given the binomial family<ef><bc><9a>the first column gives the number of successes and the second the number of failures.

PREDICTORS

A data.frame that defines the model design, which will include the predictors / features in the collumns.

HDER

The subtitle and the file name of the plot.

family

Define the family of the glm, should be one of "gaussian", "binomial", and "poisson",

CUT_OFF

The cut off of the occurence of the less abundence class in binary features, if the less frequent class is less than this threshold, the feature will be dropped, default is 5. This is important when we want to have a reliable asymptotics result in Wald test.

Critical_value

The critical value used on adjusted p values, default is 0.05.

Exclude_intercept

Whether to omit the intercept term when plot the estimates and statistics, this should be applied when the intercept estimates is too big relative to other predictors, default is FALSE.

Sort_by

Determine the order of the predictors showed in the plot, should be one of "byLogit", "byZstat", default is byLogit.

Details

The function will fit a linear model based on the provided predictors and the response variable. The coefficient estimates and the wald test statistics will be saved in a graph.


ZhenWei10/m6ALogisticModel documentation built on May 17, 2019, 10:11 p.m.