GenomicFeatures (version 1.24.4)

transcriptsByOverlaps: Extract genomic features from an object based on their by genomic location

Description

Generic functions to extract genomic features for specified genomic locations. This page documents the methods for TxDb objects only.

Usage

transcriptsByOverlaps(x, ranges, maxgap = 0L, minoverlap = 1L, type = c("any", "start", "end"), ...) "transcriptsByOverlaps"(x, ranges, maxgap = 0L, minoverlap = 1L, type = c("any", "start", "end"), columns = c("tx_id", "tx_name"))
exonsByOverlaps(x, ranges, maxgap = 0L, minoverlap = 1L, type = c("any", "start", "end"), ...) "exonsByOverlaps"(x, ranges, maxgap = 0L, minoverlap = 1L, type = c("any", "start", "end"), columns = "exon_id")
cdsByOverlaps(x, ranges, maxgap = 0L, minoverlap = 1L, type = c("any", "start", "end"), ...) "cdsByOverlaps"(x, ranges, maxgap = 0L, minoverlap = 1L, type = c("any", "start", "end"), columns = "cds_id")

Arguments

x
A TxDb object.
...
Arguments to be passed to or from methods.
ranges
A GRanges object to restrict the output.
type
How to perform the interval overlap operations of the ranges. See the findOverlaps manual page in the GRanges package for more information.
maxgap
A non-negative integer representing the maximum distance between a query interval and a subject interval.
minoverlap
Ignored.
columns
Columns to include in the output. See ?transcripts for the possible values.

Value

Details

These functions subset the results of transcripts, exons, and cds function calls with using the results of findOverlaps calls based on the specified ranges.

See Also

Examples

Run this code
  txdb <- loadDb(system.file("extdata", "hg19_knownGene_sample.sqlite",
                                   package="GenomicFeatures"))
  gr <- GRanges(seqnames = rep("chr1",2),
                ranges = IRanges(start=c(500,10500), end=c(10000,30000)),
                strand = strand(rep("-",2)))
  transcriptsByOverlaps(txdb, gr)

Run the code above in your browser using DataCamp Workspace