clickpoly {spatstat} | R Documentation |
Allows the user to create a polygon by point-and-click in the display.
clickpoly(add=FALSE, n=NULL, ...)
add |
Logical value indicating whether to create a new plot
(add=FALSE ) or draw over the existing plot (add=TRUE ).
|
n |
Number of vertices of the polygon (if this is predetermined). |
... |
Arguments passed to locator to control the
interactive plot.
|
This function allows the user to create a polygonal window by interactively clicking on the screen display.
The user is prompted to point the mouse at any desired locations
for the polygon vertices,
and click the left mouse button to add each point.
Interactive input stops after n
clicks (if n
was given)
or when the middle mouse button is pressed.
The return value is a window (object of class "owin"
)
representing the polygon.
This function uses the R{} command locator
to
input the mouse clicks. It only works on screen devices such as
‘X11’, ‘windows’ and ‘quartz’. Arguments that can be
passed to locator
through ...
include
pch
(plotting character), cex
(character expansion
factor) and col
(colour). See locator
and par
.
A window (object of class "owin"
) representing the polygon.
Adrian Baddeley adrian@maths.uwa.edu.au http://www.maths.uwa.edu.au/~adrian/ and Rolf Turner rolf@math.unb.ca http://www.math.unb.ca/~rolf
identify.ppp
,
clickppp
,
locator