circle | R Documentation |
Adds circles of radii r at coordinates specified by x and y onto an existing plot.
circle(x,y,r,border="black",lty="solid",lwd=1,fill=NULL)
x,y,r |
Vectors of the x- and y- coordinates of the midpoints and the associated radii. Vectors x, y and r should be of the same length |
border, lty, lwd |
the draving color, line type and line width of the perimeter line. Use border=NA to omit the perimeter. |
fill |
The color used to fill the circles. fill=NULL does not fill at all. |
This function is used for its side effects on the graphical display.
Lauri Mehtatalo <lauri.mehtatalo@uef.fi>
plot(0,type="n",xlim=c(-2,12),ylim=c(-2,12)) #Plot on average 7 tree crowns of Weibull-distributed radius at random locations n<-rpois(1,7) circle(x=runif(n,0,10), y=runif(n,0,10), r=rweibull(n,6,2))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.