1 / 23

Biostatistics-Lecture 12 Generalized Linear Models

Biostatistics-Lecture 12 Generalized Linear Models. Ruibin Xi Peking University School of Mathematical Sciences. Generalized liner models. GLM allow for response distributions other than normal Basic structure The distribution of Y is usually assumed to be independent and .

pavel
Download Presentation

Biostatistics-Lecture 12 Generalized Linear Models

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Biostatistics-Lecture 12Generalized Linear Models Ruibin Xi Peking University School of Mathematical Sciences

  2. Generalized liner models • GLM allow for response distributions other than normal • Basic structure • The distribution of Y is usually assumed to be independent and

  3. Generalized Linear model-an example • An example • A study investigated the roadkills of amphibian • Response variable: the total number of amphibian fatalities per segment (500m) • Explanatory variables

  4. Generalized Linear model-an example • An example • A study investigated the roadkills of amphibian • Response variable: the total number of amphibian fatalities per segment (500m) • Explanatory variables

  5. Generalized Linear model-an example • An example • A study investigated the roadkills of amphibian • Response variable: the total number of amphibian fatalities per segment (500m) • Explanatory variables • For now, we are only interested in Distance to Natural Park

  6. Generalized Linear model-an example • An example • A study investigated the roadkills of amphibian • Response variable: the total number of amphibian fatalities per segment (500m) • Explanatory variables • For now, we are only interested in Distance to Natural Park

  7. Generalized Linear model-an example • An over-simplified model • For Poisson we have

  8. GLM-exponential families • Exponential families • The density • Normal distributions is an exponential family

  9. GLM-exponential families • Consider the log-likelihood of a general exponential families Since

  10. GLM-exponential families • Differentiating the likelihood one more time using the equation We often assume Define

  11. GLM-exponential families

  12. Fitting the GLM • In a GLM • The joint likelihood is • The log likelihood

  13. Fitting the GLM • Assuming ( is known) • Differentiating the log likelihood and setting it to zero

  14. Fitting the GLM • By the chain rule • Since • We have

  15. Iteratively Reweighted Least Squares (IRLS) • We first consider fitting the nonlinear model by minimizing where f is a nonlinear function

  16. Iteratively Reweighted Least Squares (IRLS) • Given a good guess by using the Taylor expansion Define the pseudodata

  17. Iteratively Reweighted Least Squares (IRLS) • Note that in GLM, we are trying to solve • If are known, this is equivalent to minimizing

  18. Iteratively Reweighted Least Squares (IRLS) • We are inspired to use the following algorithm • At the kth iteration, define • update as in the nonlinear model case • set k to be k+1 • But the second step also involves iteration, we may perform one step iteration here to obtain

  19. Deviance • The deviance is defined as where is the log likelihood with the saturated model: the model with one parameter per data point Also note that deviance is defined to be independent of

  20. Deviance • GLM does not have R2 • The closest one is the explained deviance • The over-dispersion parameter may be estimated by or by the Pearson statistic

  21. Model comparison • Scaled deviance • For the hypothesis testing problem under H0

  22. Residuals • Pearson Residuals • Approximated zero mean and variance • Deviance Residuals

  23. Negative binomial • Density

More Related