omics2genelist {BioMM} | R Documentation

## Map individual probes into gene

### Description

Map a set of individual probes from different omics (i.e. SNPs and CpGs etc.) into genes.

### Usage

    omics2genelist(data, featureAnno, restrictUp = 500, restrictDown = 5)

### Arguments

`data` | The input dataset (either data.frame or matrix). Rows are the samples, columns are the probes, except that the first column is the label.
`featureAnno` | The annotation data stored in a data.frame for probe mapping. It must have at least two columns named 'ID' and 'entrezID'.
`restrictUp` | The upper-bound of the number of probes in each gene. The default is 500.
`restrictDown` | The lower-bound of the number of probes in each gene. The default is 5.

### Details

This function is not applicable for transcriptomic data. The data types including DNA methylation and GWAS often have several probes within one gene, therefore gene-based stratification is feasible

### Value

A list of matrices with gene IDs as the associated list member names. For each matrix, rows are the samples and columns are the probe names, except that the first column is named 'label'.

### Examples

    ## Load data from DNA methylation
    methylfile <- system.file('extdata', 'methylData.rds', package='BioMM')
    methylData <- readRDS(methylfile)
    ## Annotation files for Mapping CpGs into genes
    featureAnnoFile <- system.file('extdata', 'cpgAnno.rds', package='BioMM')
    featureAnno <- readRDS(file=featureAnnoFile)
    ## Mapping CpGs into gene list
    ## Not run
    ## dataList <- omics2genelist(data=methylData, featureAnno,
    ##                            restrictUp=100, restrictDown=5)
    ## length(dataList)

[Package BioMM version 1.0.0 Index]