[6345] in s-news-athena
Re: vector of lm.objects?
daemon@ATHENA.MIT.EDU (Richard M. Heiberger)
Wed Feb 1 12:45:53 1995
Date: Wed, 1 Feb 95 12:24:09 -0500
From: rmh@astro.ocis.temple.edu (Richard M. Heiberger)
To: aajmarc2@hilbert.spc.uchicago.edu, s-news@utstat.toronto.edu
> lmlist <- list()
> y <- rnorm(10)
> x <- rnorm(10)
> lmlist[[1]] <- lm(y~x)
> lmlist[[2]] <- lm(x~y)
> names(lmlist[[1]])
[1] "coefficients" "residuals" "fitted.values" "effects"
[5] "R" "rank" "assign" "df.residual"
[9] "contrasts" "terms" "call"
> for (i in 1:2) print(lmlist[[i]]$coef)
(Intercept) x
-0.3923924 -0.1487871
(Intercept) y
-0.6885197 -0.08405981
>