Kay,

doe this do what you want?


dotplot(y1+y2 ~ facs$Treatment|facs$Sites,
        outer=TRUE,
        scales = list(x = list(rot = 90, tck=c(1,0))),
        ylab=c("y1", "y2"),
        xlab=c("Site 1", "Site 2"),
        strip=FALSE)


On Wed, Aug 25, 2010 at 11:04 AM, Kay Cichini <kay.cich...@uibk.ac.at>wrote:

>
> hello,
>
> i want to stack two lattice plots beneath each other using one x-axis and
> sharing the same text-panels,
> like:
> #####################################################################
> library(lattice)
>
> y1 <- rnorm(100,100,10)
> y2 <- rnorm(100,10,1)
> facs<-expand.grid(Sites=rep(c("Site I","Site II"),25),Treatment=c("A","B"))
> pl1<-dotplot(y1 ~ facs$Treatment|facs$Sites,
>             scales = list(x = list(rot = 90, tck=c(1,0))))
> pl2<-dotplot(y2 ~ facs$Treatment|facs$Sites,
>             scales = list(x = list(rot = 90, tck=c(1,0))))
>
> print(pl1, split=c(1,2,1,2), more=TRUE)
> print(pl2, split=c(1,1,1,2))
> #####################################################################
>
> but as said, ideally the plots should be stacked with only the lower plot
> giving the x-axis annotation
> and only the upper plot with text-panels.
>
> thanks a lot,
> kay
>
> -----
> ------------------------
> Kay Cichini
> Postgraduate student
> Institute of Botany
> Univ. of Innsbruck
> ------------------------
>
> --
> View this message in context:
> http://r.789695.n4.nabble.com/lattice-help-required-tp2338382p2338382.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> 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<http://www.r-project.org/posting-guide.html>
> and provide commented, minimal, self-contained, reproducible code.
>

        [[alternative HTML version deleted]]

______________________________________________
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