19, 2013 9:05:17 PM
Subject: Re: [R] lattice 3x3 plot: force common y-limits accross rows and align
x-axes
Duncan and Bert,
Thank you very much for your help with my question. It's very much appreciated.
I used your suggestions to get the plot I needed:
* 3x3 lattice of dotplots,
;
> lims.low <- factor(c("A","BB"))
> lims.high <- factor(c("C","DDD"))
> dotplot(subject~count|treatment+risk,data=kf,type=c("p","h"),
> Ã Ã Ã Ã Ã Ã ÃÂ scales=c(y=list(limits=list(lims.low,lims.low,
> Ã Ã Ã Ã
hould represent
all the levels of the corresponding factor, even
if some are not used within that particular panel."
A way to trick lattice would be to use xyplot()
with a custom panel function. I'll give a try today or tomorrow.
Regards,
Boris.
__
;... to make this information consistent between panels,
the âxlimâ or âylimâ values should represent all the levels of the
corresponding factor, even if some are not used within that particular panel."
A way to trick lattice would be to use xyplot() with a custom panel function.Â
I'
Boris:
If I understand you correctly, you wish to set panel limits by row. I
know of no "slick" way of doing this (others may), as what is in a row
can change depending on layout and how you determine the scale for the
rows' contents may depend on the application context.
So I would do it manuall
Hi Duncan,
Thank you for quick reply.
I am not sure that your solution solves the problem. If I use
useOuterStrips(dotplot(count ~ subject|risk*treatment,df))
the order of subjects and panel y-limits in each panel are
A, B, BB, CCC, DD, .
However, the order of subjects and y-limits which
Hi Boris
Not sure what you mean exactly
try
library(latticeExtra)
useOuterStrips(dotplot(count ~ subject|risk*treatment,df))
if you want to change the order of the subjects in each panel and an
index column and plot the index column instead of subject and change
the scales to suit.
HTH
Dun
Good afternoon,
I would like to ask for help in controlling y-axis limits and labels in
lattice doplots. Unfortunately, the problem is somewhat convoluted,
please bear with the long explanation.
I would like to create a 3x3 lattice of dotplots, say subject ~ count.
The plot is conditioned on var
8 matches
Mail list logo