rect: Draw styled rectangles on a plot

Description Usage Arguments Examples

View source: R/RcssWrappers.R

Description

This is a wrapper for R's rect function. See R's documentation for graphics::rect for further details.

Usage

1
rect(xleft, ybottom, xright, ytop, Rcss = "default", Rcssclass = NULL, ...)

Arguments

xleft, ybottom, xright, ytop

vector of coordinates for rectangles' vertices

Rcss

style sheet object. Leave "default" to use a style defined via RcssSetDefaultStyle()

Rcssclass

character, style class

...

Further parameters, see documentation of graphics::rect

Examples

1
2
3
4
# draw rectangles on an existing plot
plot(c(0, 10), c(0, 10), type="n", xlab="", ylab="")
rect(4.5, 1, 5.5, 3)
rect(c(1, 7.5), c(6, 6), c(2.5, 9), c(8, 8))

tkonopka/Rcssplot documentation built on Jan. 21, 2021, 11:36 p.m.