GLMs in JAGS

GLMs stand for Generalized Linear Models. It is a generalization of the linear model (that assumes normality) to other distributions of the so-called exponential family (the Gaussian one is also part of this family). This model formulation allows us to fit models using several responses for the dependent variable such as binary, categorical, count, and more. For example, logistic and Poisson regression are two models that are part of this family.

In this example, we will do Bayesian logistic regression (one type of GLM). This model is appropriate when modeling a categorical response that takes two possible values. Possible examples could be modeling whether a customer is going to buy a product or not, or a student is going to pass an exam.

Both STAN and JAGS can handle not only linear regression models, but a wide array of regression models. In this exercise, we will formulate a GLM model in STAN, although it could also be done in JAGS.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.154.161