Description Usage Arguments Details Value Examples
View source: R/CoMethAllRegions.R
Extract contiguous co-methylated genomic regions from a list of pre-defined genomic regions
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
dnam |
matrix (or data frame) of beta values, with row names = CpG IDs, column names = sample IDs. This is typically genome-wide methylation beta values. |
betaToM |
indicates if converting methylation beta values to mvalues |
method |
method for computing correlation, can be "spearman" or "pearson" |
rDropThresh_num |
threshold for min correlation between a cpg with sum of the rest of the CpGs |
minCpGs |
minimum number of CpGs to be considered a "region".
Only regions with more than |
arrayType |
Type of array, can be "450k" or "EPIC" |
CpGs_ls |
list where each item is a character vector of CpGs IDs. This should be CpG probes located closely on the array. |
file |
an RDS file with clusters of CpG locations (i.e. CpGs
located closely to each other on the genome). This file can be generated
by the |
returnAllCpGs |
When there is not a contiguous comethylated region in
the inputting pre-defined region, |
output |
a character vector of CpGs or a dataframe of CpGs along with rDrop info |
nCores_int |
Number of computing cores to be used when executing code in parallel. Defaults to 1 (serial computing). |
... |
Dots for additional arguments passed to the cluster constructor.
See |
There are two ways to input genomic regions
for this function: (1) use CpGs_ls
argument
(2) use file
argument
examples of these files are in /inst/extdata/ folder of the package.
When output = "dataframe"
is selected,
returns a list of data frames, each with CpG
(CpG name), Chr
(chromosome number), MAPINFO
(genomic
position), r_drop
(correlation between the CpG with rest of the
CpGs), keep
(indicator for co-methylated CpG),
keep_contiguous
(index for contiguous comethylated subregions).
When output = "CpGs"
is selected, returns a list,
each item is a list of CpGs in the contiguous co-methylated subregion.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | data(betasChr22_df)
CpGisland_ls <- readRDS(
system.file(
"extdata",
"CpGislandsChr22_ex.RDS",
package = 'coMethDMR',
mustWork = TRUE
)
)
coMeth_ls <- CoMethAllRegions (
dnam = betasChr22_df,
betaToM = TRUE,
method = "pearson",
CpGs_ls = CpGisland_ls,
arrayType = "450k",
returnAllCpGs = FALSE,
output = "CpGs"
)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.