Re: [R] sorting in lmList object

2003-02-13 Thread Douglas Bates
[EMAIL PROTECTED] writes:

 Hi all,
 Forgive me if this is an obvious one
 I want to make a plot of confidence intervals from an lmList object with a 
 collection of simple linear models (lm(y~x)) using:
 
 plot(intervals(mylmList))
 
 and sort the plot by increasing mean values for the intercept. Is there an easy 
 way of doing this? I've tried the order() and sort.list() functions, but I 
 suspect they only work for data frames? Can I sort directly when plotting, or 
 do I have to sort the whole lmList object?

I think the easiest way to do this would be to ensure that the
grouping factor that you pass to lmList is an ordered factor with the
desired ordering.  This may involve two passes through lmList - the
first to get the ordering and the second to create an lmList object
with the desired ordering.

__
[EMAIL PROTECTED] mailing list
http://www.stat.math.ethz.ch/mailman/listinfo/r-help



[R] sorting in lmList object

2003-02-12 Thread emb7
Hi all,
Forgive me if this is an obvious one
I want to make a plot of confidence intervals from an lmList object with a 
collection of simple linear models (lm(y~x)) using:

plot(intervals(mylmList))

and sort the plot by increasing mean values for the intercept. Is there an easy 
way of doing this? I've tried the order() and sort.list() functions, but I 
suspect they only work for data frames? Can I sort directly when plotting, or 
do I have to sort the whole lmList object?

Thanks!

Martin




--
Sent through WebMail: http://webmail.st-andrews.ac.uk/

__
[EMAIL PROTECTED] mailing list
http://www.stat.math.ethz.ch/mailman/listinfo/r-help