Description Usage Arguments Value See Also Examples
This is a wrapper function which calls one of following functions depending
on annotType parameter: getFeatureCounts
,
getFeatureCountsBig
, getNearestFeature
,
get2NearestFeature
, getSitesInFeature
1 2 | doAnnotation(annotType = NULL, ..., postProcessFun = NULL,
postProcessFunArgs = list())
|
annotType |
one of following: within, nearest, twoNearest, counts, countsBig. |
... |
Additional parameters to be passed to the respective annotation function. |
postProcessFun |
function to call on the resulting object for any post processing steps. |
postProcessFunArgs |
additional arguments for postProcessFun as a list. |
a GRanges object with new annotation columns appended at the end of sites.rd.
makeGRanges
, getFeatureCounts
,
getFeatureCountsBig
, getNearestFeature
,
get2NearestFeature
, getSitesInFeature
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | # Convert a dataframe to GRanges object
data(sites)
alldata.rd <- makeGRanges(sites, soloStart = TRUE)
data(genes)
genes.rd <- makeGRanges(genes)
doAnnotation(annotType = "within", alldata.rd, genes.rd, "InGene", asBool = TRUE)
## Not run:
doAnnotation(annotType = "counts", alldata.rd, genes.rd, "NumOfGene")
doAnnotation(annotType = "nearest", alldata.rd, genes.rd, "NearestGene")
doAnnotation(annotType = "countsBig", alldata.rd, genes.rd, "ChipSeqCounts")
geneCheck <- function(x,wanted) { x$isWantedGene <- x$InGene %in% wanted;
return(x) }
doAnnotation(annotType = "within", alldata.rd, genes.rd, "InGene",
postProcessFun = geneCheck,
postProcessFunArgs = list("wanted" = c("FOXJ3", "SEPT9", "RPTOR")) )
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.