[R] lattice panel.linejoin type question

Walker, Sam s-walker at ti.com
Tue Jan 2 16:28:20 CET 2007


Hello R Users!

I'm trying to use the panel.linejoin function to draw points and lines
(type="o") but it wouldn't do it.  Modifying the panel.linejoin function
as such (adding type argument to the panel.lines call).
 
*original*
        panel.lines(vals[xx], yy, col = col.line, lty = lty, 
            lwd = lwd, ...)
*modified
        panel.lines(vals[xx], yy, col = col.line, lty = lty, 
            lwd = lwd, type, ...)


Then passing the type="o" in the panel.linejoin call as such works.
xyplot(
	...
	,panel.groups=function(x,y,subscripts,...) {
 		panel.linejoin(x,y,fun=mean,type="o",...)
	}
)

However, if I don't add the "type" in the panel.lines call, I get a
"formal argument "type" matched by multiple actual arguments" Error.

It seems like overkill to redefine panel.lines, is there a simpler way?


R 2.4.1 Windows XP
Lattice 0.14-16

Best Regards,
Sam



More information about the R-help mailing list