plot.feat: Features plot

Description Usage Arguments Author(s) Examples

View source: R/feat.R

Description

plot features

Usage

1
2
3
4
5
## S3 method for class 'feat'
plot(x, y = 0, height = 1, plottype = "r",
  arrow.density = 5, angle = 30, col = "black", fill.col = if (plottype
  == "r") col else NULL, lty = par("lty"), lwd = par("lwd"), add = FALSE,
  xlim = range.feat(x), ylim = c(y - height * 3/4, y + height * 3/4), ...)

Arguments

x

an object of type feat

y

the location of the plot on the y axis

height

the height of the boxes

plottype

either "r" for rectangles or "a" for arrows, "b" for arrows within rectangles, or "l" for line segments only.

arrow.density

If plottype=="a" or "b", then this gives the density of arrows in arrows per inch. Otherwise it gives the density of shading lines in the rectangles, and a value of NULL implies no shading lines.

angle

angle (in degrees) of the shading lines or arrows.

col

color to draw the boxes/lines/arrows with.

fill.col

Color to fill the rectangles with. If NULL then do not fill.

lty

line type for lines, arrows, borders, and shading

lwd

line width for lines, arrows, borders and shading

add

if TRUE, add to existing plot

xlim

A numerical vector of length 2 giving the range for the x-axis.

ylim

A numerical vector of length 2 giving the range for the y-axis.

...

graphical parameters to be passed to plot.

Author(s)

Melissa J. Hubisz

Examples

1
2
3
4
5
6
7
exampleArchive <- system.file("extdata", "examples.zip", package="rphast")
featFile <- "gencode.ENr334-100k.gff"
unzip(exampleArchive, featFile)
f <- read.feat(featFile)
# note that plot(f) does not work because features are stored as data.frames
plot.feat(f[f$feature=="CDS",])
unlink(featFile)

Example output



rphast documentation built on May 1, 2019, 9:26 p.m.