[R] Probit predictions outside (0,1) interval

Prof Brian Ripley ripley at stats.ox.ac.uk
Fri Mar 5 09:24:45 CET 2004


On Fri, 5 Mar 2004, Arnab mukherji wrote:

> I was trying to implement a probit model on a dichotomous outcome
> variable and found that the predictions were outside the (0,1) interval
> that one should get. I later tried it with some simulated data with a
> similar result.
> 
> Here is a toy program I wrote and I cant figure why I should be getting
> such odd predictions.

Did it occur to you to read the help page?  The default type of prediction 
is "link", not "response".  Do try ?predict.glm.

...
> yhat<-predict(g, dat)
...

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list