[R] Retrieving predictions after fitting a model

Ben Bolker bbolker at gmail.com
Wed Sep 1 01:32:56 CEST 2010


alexander pswarayi <pswarayi <at> ualberta.ca> writes:

> 
> Hi there
> 
> I am trying to retrieve the predicted values after fitting a model (dose
> response model). How do I do it. What is the code for it? For estimated
> parameters, one uses : summary(filename). And for the predicted values, what
> do I use? Many thanks.

  It depends on the model, but try

predict()

and/or

fitted()

  (See the generic help pages ?predict and ?fitted, also possibly
the specific help pages corresponding to your model type, for example
?predict.glm)

  If you need more detail, you're going to have to give us more detail
about what you did.



More information about the R-help mailing list