I tried to emulate the axis interval calculation behaviour of the traditional 
graphics system (with par(xaxs="i")) in lattice but couldn't find a flexible 
solution.

Let's say a have a simple xyplot:

x <- seq(0, 1, 0.01)
xyplot(x^2 ~ x, type="l")

I want to restrict the plotting region to the data range _and_ have axis 
labels over the full data range like this:

xyplot(x^2 ~ x, type="l", xlim=0:1, ylim=0:1,
scales=list(labels=seq(0, 1, 0.2)))

Is there a simple way to achieve this in a more general fashion (e.g. with 
lattice options) so that the behaviour could be applied to a whole set of 
plots?

Thomas Zumbrunn

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to