Learn R Programming

berryFunctions (version 1.11.0)

locLine: abline at locator point in graph

Description

Draw vertical and/or horizontal lines at positions in a graph located by clicking

Usage

locLine(h = TRUE, v = TRUE, n = 1, ...)

Arguments

h
Draw horizontal line at clicked location? DEFAULT: TRUE
v
Draw vertical line at clicked location? DEFAULT: TRUE
n
Number of points to be clicked. DEFAULT: 1
...
Further arguments passed to abline like lty, lwd, col, etc

Value

locator result

Details

Not tested across platforms yet...

See Also

locator, abline

Examples

Run this code

plot(cumsum(rnorm(60)), type="l")
## locLine() # only do this manually in interactive() mode

Run the code above in your browser using DataLab