Finish writing ##untested## GLM code.