Learn R Programming

recoup (version 1.0.2)

coverageRnaRef: Calculate coverage in a set of reference genomic regions (RNA-Seq or spliced mode)

Description

This function fills the coverage field in the main input argument in recoup function.

Usage

coverageRnaRef(
        input, 
        genomeRanges, 
        helperRanges,
        flank,
        strandedParams = list(strand=NULL, ignoreStrand=TRUE),
        bamParams = NULL,
        rc = NULL
    )

Arguments

input
an input list as in recoup but with the ranges field of each member filled (e.g. after using preprocessRanges).
genomeRanges
a named GRangesList where list member names are genes and list members are GRanges representing each gene's exons.
helperRanges
the genome from recoup as a GRanges object (e.g. the output from makeGRangesFromDataFrame).
flank
see the flank argument in the main recoup function.
strandedParams
see the strandedParams argument in the main recoup function.
bamParams
see the bamParams argument in the main recoup function.
rc
fraction (0-1) of cores to use in a multicore system. It defaults to NULL (no parallelization).

Value

  • Same as input with the ranges fields filled.

Examples

Run this code
# Load some data
data("recoup_test_data",package="recoup")

# Note: the figures that will be produced will not look 
# realistic or pretty and will be "bumpy". This is because 
# package size limitations posed by Bioconductor guidelines 
# do not allow for a full test dataset. As a result, the input
# below is not an RNA-Seq dataset. Have a look at the
# vignette on how to test with more realistic data.

# Calculate coverages
testGenomeRanges <- makeGRangesFromDataFrame(df=test.genome,
    keep.extra.columns=TRUE)
test.input <- coverageRnaRef(
    test.input,
    genomeRanges=test.exons,
    helperRanges=testGenomeRanges,
    flank=c(2000,2000)
)

Run the code above in your browser using DataLab