Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/methylation_preprocessing.R

Estimated methylation call based on the fitting results of `gammaFitEM`

1 | ```
methylationCall(x, threshold = 0.95, ...)
``` |

`x` |
a vector of M-values covering the whole genome or a "gammaFit" class object returned by |

`threshold` |
the probability threshold to make a methylation call. The threshold can be a vector of two: unmethylation threshold and methylation threshold |

`...` |
other parameters used by |

Retrieve the probability element returned by `gammaFitEM`

, and convert it as three status calls based on probability threshold

NOTE: the methylation status modeling algorithm was developed based on 27K methylation array. It has not been tested for 450K array. Considering 450K array covers both promoter and gene body, the two component Gamma mixture model assumption may not be valid any more.

A vector of three methylation status: "Unmethy" (unmethylation posterior probability > unmethylation threshold), "Methy" (methylation posterior probability > methylation threshold), or "Margin". The sum of unmethylation posterior probability and methylation posterior probability equals one. The methylation probability is returned as an attribute of "probability".

Pan DU

1 2 3 4 5 | ```
data(example.lumiMethy)
M <- exprs(example.lumiMethy)
fittedGamma <- gammaFitEM(M[,1], initialFit=NULL, maxIteration=50, tol=0.0001, plotMode=TRUE, verbose=FALSE)
methyCall <- methylationCall(fittedGamma)
table(methyCall)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.