ewaff.handle.outliers: Handle outliers

View source: R/handle-outliers.r

ewaff.handle.outliersR Documentation

Handle outliers

Description

Handle outliers

Usage

ewaff.handle.outliers(
  methylation,
  method = c("iqr", "winsorize"),
  iqr.limit = 3,
  winsorize.pct = 0.05
)

Arguments

methylation

DNA methylation matrix, one row per CpG site, one column per sample.

method

The method for handling outliers. Options are 'iqr' (default) and 'winsorize'. The 'iqr' option sets observations beyond a user-defined mutliple of the inter-quartile (iqr.limit) to NA. The 'winsorize' option sets observations beyond the winsorize.pct or 1-winsorize.pct percentiles to the corresponding percentile.

iqr.limit

The multiple of IQR beyond which observations should be set to NA. Default is 3.

winsorize.pct

The percentile used for winsorizing observations. Default is 0.05.

Value

List containing the methylation matrix with outliers modified depending on the method selected, and a log of how many observations were identified for each probe.


perishky/ewaff documentation built on Jan. 31, 2024, 11:29 p.m.