How to correctly specify constraints for Knorr-Held Type II - IV Gaussian Markov Random Fields in INLA (but also any GMRF with a singular precision matrix, generally speaking).
- example.R: All the code you will need to walk through a simple example for Ohio. Will give you examples for Type II - IV random effects as well as literally any precision matrix using nice linear algebra facts.
- ohioadj.asc: The graph file you'll need to run the example code.
Details are in commented sections of example.R!