assignMissingID: Annotate ranges with missing IDs.

Description Usage Arguments Value See Also Examples

Description

This function can relabel ranges with missing IDs (i.e. returned by assignTxID and assignGeneID), in case they need to be retained for further analysis.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
assignMissingID(object, ...)

## S4 method for signature 'character'
assignMissingID(object, prefix = "Novel")

## S4 method for signature 'GenomicRanges'
assignMissingID(object, outputColumn = "geneID", prefix = "Novel")

## S4 method for signature 'RangedSummarizedExperiment'
assignMissingID(object, outputColumn = "geneID", prefix = "Novel")

Arguments

object

character, GRanges or RangedSummarizedExperiment: IDs to have NAs replaces with new IDs.

...

additional arguments passed to methods.

prefix

character: New name to assign to ranges with missing IDs, in the style prefix1, prefix2, etc.

outputColumn

character: Name of column to hold txID values.

Value

object with NAs replaced in outputColumn

See Also

Other Annotation functions: assignGeneID(), assignTxID(), assignTxType()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
data(exampleUnidirectional)

# Obtain gene models from a TxDb-object:
library(TxDb.Mmusculus.UCSC.mm9.knownGene)
txdb <- TxDb.Mmusculus.UCSC.mm9.knownGene

# Assign geneIDs using only TC peaks:
exampleUnidirectional <- assignGeneID(exampleUnidirectional,
                                      geneModels=txdb,
                                      outputColumn='geneID',
                                      swap='thick')

# Replace NAs with 'Novel'
assignMissingID(exampleUnidirectional)

# Replace NAs with 'NovelTSS'
assignMissingID(exampleUnidirectional, prefix = 'NovelTSS')

MalteThodberg/CAGEfightR documentation built on Sept. 11, 2021, 4:42 a.m.