# Exploring Links for the Gaussian Distribution

### Building Models

Pretending we don't know the correct answer, lets see if we can find the correct model. For a change we will compare the the link functions for the gaussian family.

glmIdentity <- glm(Y ~ X1 + X2, data = simdata, family = gaussian(link = "identity")) glmInverse<- glm(Y ~ X1 + X2, data = simdata, family = gaussian(link = "inverse")) glmLog<- glm(Y ~ X1 + X2, data = simdata, family = gaussian(link = "log")) summary(glmIdentity) summary(glmInverse) summary(glmLog)

Again, the correct model has the lowest AIC and the estimated weights are very close to the true values.

# Summary

We have explored different links for the gaussian distribution, but the gaussian distribution is not a special case. Everything that was done here could be done for any distribution in the glm framework. Once you understand one distribution, you are very far along in understanding the other distributions. The glm framework can handle categorical response variables (binomial), integer response variables (poisson), and right skewed response variables (gamma and inverse gaussion).