Description Usage Arguments Value Author(s) See Also Examples
Function to generate a variety of feature types from TxDb
objects using
utilities provided by the GenomicFeatures
package. The feature types are
organized per gene and can be returned on that level in their non-reduced or
reduced form.
Currently, supported features include intergenic
, promoter
,
intron
, exon
, cds
, 5'/3'UTR
and different
transcript
types. The latter contains as many transcript types as
available in the tx_type
column when extracting transcripts from
TxDb
objects as follows:
transcripts(txdb, c("tx_name", "gene_id", "tx_type"))
1 | genFeatures(txdb, featuretype = "all", reduce_ranges, upstream = 1000, downstream = 0, verbose = TRUE)
|
txdb |
|
featuretype |
Feature types can be specified by assigning a |
reduce_ranges |
If set to |
upstream |
Defines for promoter features the number of bases upstream from the transcription start site. |
downstream |
Defines for promoter features the number of bases downstream from the transcription start site. |
verbose |
|
The results are returned as a GRangesList
where each component is a
GRanges
object containing the range set of each feature type. Intergenic
ranges are assigned unique identifiers and recorded in the featuretype_id
column of the metadata block. For this the ids of their adjacent genes are concatenated with two
underscores as separator. If the adjacent genes overlap with other genes then
their identifiers are included in the id string as well and separated by a single
underscore.
Thomas Girke
transcripts
and associated TxDb
accessor functions from
the GenomicFeatures
package.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ## Sample from GenomicFeatures package
library(GenomicFeatures)
gffFile <- system.file("extdata", "GFF3_files", "a.gff3", package="GenomicFeatures")
txdb <- makeTxDbFromGFF(file=gffFile, format="gff3", organism="Solanum lycopersicum")
feat <- genFeatures(txdb, featuretype="all", reduce_ranges=FALSE, upstream=1000, downstream=0)
## List extracted feature types
names(feat)
## Obtain feature lists by genes, here for promoter
split(feat$promoter, unlist(mcols(feat$promoter)$feature_by))
## Return all features in single GRanges object
unlist(feat)
## Not run:
## Sample from systemPipeRdata package
file <- system.file("extdata/annotation", "tair10.gff", package="systemPipeRdata")
txdb <- makeTxDbFromGFF(file=file, format="gff3", organism="Arabidopsis")
feat <- genFeatures(txdb, featuretype="all", reduce_ranges=FALSE, upstream=1000, downstream=0)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.