meffil.ewas.old: Epigenome-wide association study (OLD VERSION RETAINED FOR...

View source: R/ewas-old.r

meffil.ewas.oldR Documentation

Epigenome-wide association study (OLD VERSION RETAINED FOR COMPARISON)

Description

Test association with each CpG site.

Usage

meffil.ewas.old(
  beta,
  variable,
  covariates = NULL,
  batch = NULL,
  weights = NULL,
  cell.counts = NULL,
  isva = T,
  sva = T,
  smartsva = F,
  n.sv = NULL,
  isva0 = F,
  isva1 = F,
  winsorize.pct = 0.05,
  robust = TRUE,
  rlm = FALSE,
  outlier.iqr.factor = NA,
  most.variable = min(nrow(beta), 50000),
  featureset = NA,
  random.seed = 20161123,
  lmfit.safer = F,
  verbose = F
)

Arguments

beta

Methylation levels matrix, one row per CpG site, one column per sample.

variable

Independent variable vector.

covariates

Covariates data frame to include in regression model, one row per sample, one column per covariate (Default: NULL).

batch

Batch vector to be included as a random effect (Default: NULL).

weights

Non-negative observation weights. Can be a numeric matrix of individual weights of same dimension as beta, or a numeric vector of weights with length ncol(beta), or a numeric vector of weights with length nrow(beta).

cell.counts

Proportion of cell counts for one cell type in cases where the samples are mainly composed of two cell types (e.g. saliva) (Default: NULL).

isva

Apply Independent Surrogate Variable Analysis (ISVA) to the methylation levels and include the resulting variables as covariates in a regression model (Default: TRUE).

sva

Apply Surrogate Variable Analysis (SVA) to the methylation levels and covariates and include the resulting variables as covariates in a regression model (Default: TRUE).

smartsva

Apply the SmartSVA algorithm to the methylation levels and include the resulting variables as covariates in a regression model (Default: FALSE).

n.sv

Number of surrogate variables to calculate (Default: NULL).

winsorize.pct

Apply all regression models to methylation levels winsorized to the given level. Set to NA to avoid winsorizing (Default: 0.05).

robust

Test associations with the 'robust' option when limma::eBayes is called (Default: TRUE).

rlm

Test assocaitions with the 'robust' option when limma:lmFit is called (Default: FALSE).

outlier.iqr.factor

For each CpG site, prior to fitting regression models, set methylation levels less than Q1 - outlier.iqr.factor * IQR or more than Q3 + outlier.iqr.factor * IQR to NA. Here IQR is the inter-quartile range of the methylation levels at the CpG site, i.e. Q3-Q1. Set to NA to skip this step (Default: NA).

most.variable

Apply (Independent) Surrogate Variable Analysis to the given most variable CpG sites (Default: 50000).

featureset

Name from meffil.list.featuresets() (Default: NA).

verbose

Set to TRUE if status updates to be printed (Default: FALSE).


perishky/meffil documentation built on June 9, 2024, 5:59 p.m.