Re: [R] storing objects (lm results) in an array

2003-09-24 Thread Peter Dalgaard BSA
Jason Turner <[EMAIL PROTECTED]> writes: > On Thu, 2003-09-25 at 05:34, Christoph Lehmann wrote: > > Hi > > > > I have calculated lots (>1000) of linear models and would like to store > > each single result as an element of a 3D matrix or a similar storage: > > something like > > > > glm[i][j][k

Re: [R] storing objects (lm results) in an array

2003-09-24 Thread Spencer Graves
As you noted, the output of, e.g., "lm" is a list. When I've done many fits like this, I've usely been interested in only a few components of the list. In that case, I first construct a matrix or higher dimensional array and then store what I want in that array. Example: > DF0 <- data.frame

Re: [R] storing objects (lm results) in an array

2003-09-24 Thread Jason Turner
On Thu, 2003-09-25 at 05:34, Christoph Lehmann wrote: > Hi > > I have calculated lots (>1000) of linear models and would like to store > each single result as an element of a 3D matrix or a similar storage: > something like > > glm[i][j][k] = lm(...) > > Since I read that results are lists: Is i

[R] storing objects (lm results) in an array

2003-09-24 Thread Christoph Lehmann
Hi I have calculated lots (>1000) of linear models and would like to store each single result as an element of a 3D matrix or a similar storage: something like glm[i][j][k] = lm(...) Since I read that results are lists: Is it possible to define a matrix of type list? Or what do you recommend?