Marlin Keith Cox wrote: > Z is a matrix and when I run the following line, it creates a prediction > estimate using each column, how can I get it an estimate for each individual > number. I have tried changing Z to a data.frame, but this does not do it > either. > > model.lm<-lm(w~x) > > pred.est <- predict.lm(model.lm, data.frame(x=Z))
That's what I do and it always worked for me. Can you please specify a reproducible example that shows what you got and tells us exactly what you expected? BTW: It is expected that you call the generic predict() rather than its particular method. Uwe Ligges > Thanks in advance, > keith > ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.