[Rd] lm() appears to fail with large number of variables (PR# 744)

Bill.Venables@CMIS.CSIRO.AU Bill.Venables@CMIS.CSIRO.AU
Thu, 23 Nov 2000 06:53:43 +1000


This is not a bug, only evidence that the least squares fitting procedure is
more numerically robust than I had expected.

With 11 observations you can only estimate 11 linearly independent
regression coefficients (at best).  That's what you got (intercept + first
10 variables).  How many did you expect to get estimates for?

In summary: no bug, lm is working as advertised.

> -----Original Message-----
> From: r@marksmucker.com [mailto:r@marksmucker.com]
> Sent: Thursday, 23 November 2000 6:29
> To: r-devel@stat.math.ethz.ch
> Cc: R-bugs@biostat.ku.dk
> Subject: [Rd] lm() appears to fail with large number of variables
> (PR#744)
> 
> 
> Full_Name: Mark Smucker
> Version: 1.1.1
> OS: Windows NT
> Submission from: (NULL) (63.91.145.254)
> 
> 
> 
> Hi,
> 
> I have a data frame with 11 observations and 603 variables.
> 
> When I call,
> 
>     willRaw.fit <- lm( performance ~ ., data=willRaw )
> 
> lm() runs without problems, but computes coefficients for
> only the first 10 variables.  The remaining variables
> get a coefficient of NA.
> 
> There are no NA values in the data frame.  performance
> is one of the columns of the data frame.  I'd be happy
> to email the data file (gzip'd or zip'd).
> 
> My apologies if I've done some stupid (yes, I know it's
> not wise to fit a model to 603 variables, but I was
> just playing around).
> 
> Mark
> 
>  
> 
> -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.
> -.-.-.-.-.-.-.-.-
> r-devel mailing list -- Read 
> http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
> Send "info", "help", or "[un]subscribe"
> (in the "body", not the subject !)  To: 
> r-devel-request@stat.math.ethz.ch
> _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.
> _._._._._._._._._
> 
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._