[S] Equally scaled plots with xyplot (like eqscplot or scaled.plot)

Jacob A. Wegelin (wegelin@stat.washington.edu)
Wed, 21 Oct 1998 14:19:46 -0700 (PDT)


This same question has been posted by Kemal Buyukkurt on 98/09/26, and by
Nick Ellis on 1997/04/18. I don't find any answers, however, in my search
of aus.stats.s. Not even anybody saying "it can't be done." So at the
risk of being redundant, here's the question again, re-worded.

The functions

eqscplot() (from Venables and Ripley's library)

and

scaled.plot() (from Frank Harrell's Hmisc library)

are very handy. So is xyplot(), with its multipanel conditioning.

Is there a straightforward way to call xyplot() such that the plot in each
panel will be equal-scaled?

For instance, if

x <- rep(1:5,2)
y<-rep(1,10) + rnorm(x)/10
junk<-data.frame(x=x, y=y, group=c(rep("a",5), rep("b",5)))

a way to do

xyplot(y ~ x | group, data=junk, etc etc )

so that the scales on the x and y axes will be identical, just as though
one had typed

scaled.plot(x,y)

separately for each group.

By fiddling with the aspect argument, I was able to make plots that looked
approximately equal-scaled. But that's not the same as a command that
guarantees equal scales.

And here's another question in the same spirit.

If you call Frank Harrell's pstamp() function after making a plot, it
prints the date and time in a tiny font in the lower right hand of the
plot.

If you call xyplot with, for instance, layout=c(4,3,12), is there any
way to get a pstamp() on each page of the plot?

Thanks for any insights

Jake

-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news