Skip to content

logistic regression with glm: cooks distance and dfbetas are different compared to SPSS output

1 message · Uwe Ligges

#
On 29.04.2011 18:29, "Biedermann, J?rgen" wrote:
Just type stats::cooks.distance.glm and see the definition in R yourself:

function (model, infl = influence(model, do.coef = FALSE), res = 
infl$pear.res, dispersion = summary(model)$dispersion, hat = infl$hat, ...)
{
     p <- model$rank
     res <- (res/(1 - hat))^2 * hat/(dispersion * p)
     res[is.infinite(res)] <- NaN
     res
}
<environment: namespace:stats>

Now you can digg yourself further on. I do not know how to find the 
actually used algorithm from SPSS, hence I cannot tell what is different.

Uwe Ligges