gene_tracks.Rd
Generate gene tracks with GViz.
gene_tracks( experiment, feature_name, genome_annotation = NULL, feature_type = "gene", samples = "all", threshold = NULL, upstream = 250, downstream = 250, promoter_only = FALSE, use_normalized = FALSE, tss_colors = "black", tsr_colors = "black", axis_scale = 0.25, ymax = NA, anno_pos = "top" )
experiment | TSRexploreR object. |
---|---|
feature_name | Name of gene or transcript to visualize |
genome_annotation | Genome annotation in GTF, GFF3, or TxDb format. |
feature_type | Either 'gene' or 'transcript' |
samples | Names of samples to plot. Append sample names with 'TSS:' or 'TSR:' for TSS and TSR tracks, respectively. |
threshold | TSSs or TSRs with a score below this value will not be considered. |
upstream | Bases upstream to extend gene or promoter track. |
downstream | Bases downstream to extend gene or promoter track. |
promoter_only | Instead of plotting the entire gene, plot only the promoter region. |
use_normalized | Whether to use the normalized (TRUE) or raw (FALSE) counts. |
tss_colors | Either a single color value for all TSS tracks, or a vector of colors. |
tsr_colors | Either a single color value for all TSR tracks, or a vector of colors. |
axis_scale | Relative size scale for axis text and title. |
ymax | Maximum value on y-axis for all TSS tracks. |
anno_pos | Genome annotation and axis track position. Either 'top' or 'bottom'. |
GViz gene track plot.
This function generates a GViz gene track of either the promoter region, or the specified gene or transcript and surrounding region. The gene or transcript name should be supplied to 'feature_name'. 'promoter_only' controls whether the plot is of the feature promoter or the entire gene. 'upstream' and 'downstream' is relative to either the the TSS (if promoter only) or the feature boundaries (if gene/transcript).
data(TSSs_reduced) annotation <- system.file("extdata", "S288C_Annotation.gtf", package="TSRexploreR") exp <- TSSs_reduced %>% tsr_explorer(genome_annotation=annotation) %>% format_counts(data_type="tss") %>% tss_clustering(threshold=3)#>#>#>#>#>#> Warning: The "phase" metadata column contains non-NA values for features of type #> stop_codon. This information was ignored.#>#> Warning: Arguments in '...' ignored#> Warning: Arguments in '...' ignored