how check overfitting on point pattern on a linear network using spatstat

Viewed 41

I have been using lppm (point pattern on a linear network) on spatstat with bunch of covariates and fitting a log-linear model but I couldn't see how to check over-fitting. Is there a quick way to do it?

1 Answers

It depends on what you want.

What tool would you use to check overfitting in (say) a linear model?

To identify whether individual observations may have been over-fitted, you could use influence.lppm (from the spatstat.linnet package).

To identify collinearity in the covariates, currently we do not provide a dedicated function in spatstat, but you could use the following trick. If fit is your fitted model of class lppm, first extract the corresponding GLM using

g <- getglmfit(as.ppm(fit))

Next install the package faraway and use the vif function to calculate the variance inflation factors

library(faraway)
vif(g)
Related