Add a Plot for Kernel Density Estimation for Circular Data
The lines add a plot for density.circular objects.
## S3 method for class 'density.circular'
lines(x, type = "l", zero.line = TRUE,
  points.plot = FALSE, points.col = 1, points.pch = 1, points.cex = 1,
  plot.type = c("circle", "line"), bins = NULL, offset=1, shrink = 1,
  tcl = 0.025, sep = 0.025, join = TRUE, nosort = FALSE,
  plot.info = NULL, zero = NULL, rotation = NULL, ...)x | 
 an object of class   | 
type | 
 plotting parameter with useful default.  | 
zero.line | 
 logical; if   | 
points.plot | 
 logical; if   | 
points.col, points.pch, points.cex | 
 parameters used to draw the points.  | 
plot.type | 
 type of the plot.  | 
bins | 
 number of ticks to plot.  | 
offset | 
 the radius of the circle  | 
shrink | 
 parameter that controls the size of the plotted function. Default is 1.  | 
tcl | 
 length of the ticks.  | 
sep | 
 constant used to specify the distance between stacked points. Default is 0.025; smaller values will create smaller spaces.  | 
join | 
 logical: should the first and the last point joined.  | 
nosort | 
 logical: should the data sort before plotting. Defaults is to sort.  | 
plot.info | 
 an object from   | 
zero | 
 the zero of the plot. Ignored if   | 
rotation | 
 the rotation of the plot. Ignored if   | 
... | 
 futher parameters passed to   | 
A list with information on the plot: zero, rotation and next.points and, if available, the coordinates x and y.
Claudio Agostinelli
set.seed(1234) x <- rvonmises(n=100, mu=circular(pi), kappa=2) y <- rvonmises(n=100, mu=circular(pi/2), kappa=2) resx <- density(x, bw=25) res <- plot(resx, points.plot=TRUE, xlim=c(-1.5,1), ylim=c(-1.1, 1.5)) resy <- density(y, bw=25) lines(resy, points.plot=TRUE, col=2, points.col=2, plot.info=res)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.