regionalplot.genelabels: Plot genes as arrows

Description Usage Arguments Details Value Note Author(s)

View source: R/HLP_genelabels_plot.R

Description

Plotting of genes and exones incl. gene labels

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
regionalplot.genelabels(
  genes,
  levels,
  exons,
  xstart,
  xstop,
  ystart,
  ygenesize,
  scale.factor,
  arrow.scale.factor = scale.factor,
  truncate = TRUE,
  genecol = "forestgreen",
  genenamecol = "black"
)

Arguments

genes

a dataframe of genes to plot, with columns start, end, name, strand. strand = -1 or - means minus strand, everything else plus strand.

levels

integer giving desired number of layers to plot multiple genes. Genes are assigned to layers via gene start position. If NULL, an additional column ypos is expected in genes giving the y-coordinates for the genes to plot.

exons

a data frame containing columns exon_chrom_start and exon_chrom_end with start and end positions of exons. Additionally, columns start and end with respective gene coordinates are needed as in genes. Exon plotting omitted if NULL.

xstart

an integer number defining the smallest base position of the plot packet.

xstop

an integer number defining the largest base position of the plot packet.

ystart

numeric y position of the line marking the gene.

ygenesize

numeric y extentsion.

scale.factor

character expansion value as in e.g xyplot. Is also used for other scaling calculations (e.g. exon size, lwd) here.

arrow.scale.factor

character expansion value for arrows.

truncate

When TRUE, gene start / end positions will be truncated to xstart and xstop. Exons with exon_chrom_start > xstop or exon_chrom_end < xstart are dicarded (that are those that lie completely beyond xstart and xstop).

genecol

character giving gene color.

genenamecol

character giving color of gene names.

Details

Shows an arrow (orientation = strand) and the according gene symbol in the plot. Can also mark exons with a thickening of the gene line.

Value

no value returned. Genes are plotted in active graphics device.

Note

Arrowheads are omitted (with a warning) on any arrow of length less than 1/1000 inch (see help(arrows) from graphics package)

Author(s)

Milan Hiersche and Frank Ruehle


frankRuehle/systemsbio documentation built on Sept. 14, 2020, 1:18 a.m.