1 / 34

GLM I: Introduction to Generalized Linear Models

GLM I: Introduction to Generalized Linear Models. By Curtis Gary Dean Vice President and Actuary,. Classical Multiple Linear Regression. Y i = a 0 + a 1 X i 1 + a 2 X i 2 …+ a m X im + e i Y i are the response variables and X ij are predictors

Download Presentation

GLM I: Introduction to 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. GLM I: Introduction to Generalized Linear Models By Curtis Gary Dean Vice President and Actuary,

  2. Classical Multiple Linear Regression • Yi= a0 + a1Xi1 + a2Xi2 …+ amXim + ei • Yi are the response variables and Xij are predictors • ei is random error term: Normally distributed • E[ei] = 0 and Var(ei) = σ2 is constant

  3. Classical Multiple Linear Regression • μi = E[Yi] = a0 + a1Xi1 + …+ amXim • Yi is Normally distributed random variable with variance σ2 • Want to estimate μi = E[Yi] for each i

  4. Problems with Traditional Model • Number of claims is discrete • Claim sizes are skewed to the right • Probability of an event is in [0,1] • Variance is not constant across data points i • Nonlinear relationship between X’s and Y’s

  5. Generalized Linear Models - GLMs • Fewer restrictions • Y can model number of claims, probability of renewing, loss severity, loss ratio, etc. • Large and small policies can be put into one model • Y can be nonlinear function of X’s • Classical linear regression model is a special case

  6. Generalized Linear Models - GLMs • g(μi )= a0 + a1Xi1 + …+ amXim • g( ) is the link function • E[Yi] = μi= g-1(a0 + a1Xi1 + …+ amXim) • Yi can be Normal, Poisson, Gamma, Binomial, Compound Poisson, … • Variance can be modeled

  7. Exponential Family of Distributions

  8. Normal Distribution in Exponential Family

  9. Some Math Rules: Refresher

  10. Poisson Distribution in Exponential Family

  11. Poisson Distribution in Exponential Family

  12. Compound Poisson Distribution • Y = C1 + C2 + . . . + CN • N is Poisson random variable • Ciare i.i.d. with Gamma distribution • This is an example of a Tweedie distribution • Y is member of Exponential Family

  13. Members of the Exponential Family • Normal • Poisson • Binomial • Gamma • Inverse Gaussian • Compound Poisson

  14. Variance Structure • E[Yi] = μi = b' (θi) → θi= b' (-1)(μi ) • Var[Yi] = a(Φi) b' ' (θi) = a(Φi) V(μi) • Common form: Var[Yi] = Φ V(μi)/wi • Φis constant across data butweights applied to data points

  15. Variance Functions V(μ) V(μ) • Normal 0 • Poisson  • Binomial (1-) • Tweedie p, 1<p<2 • Gamma 2 • Inverse Gaussian 3 • Recall: Var[Yi] = Φ V(μi)/wi

  16. Variance at Point and Fit A Practioner’s Guide to Generalized Linear Models: A CAS Study Note

  17. Why Exponential Family? • Distributions in Exponential Family can model a variety of problems • Standard algorithm for finding coefficients a0, a1, …, am

  18. Modeling Number of Claims

  19. Assume a Multiplicative Model • μi = expected number of claims in five years • μi = BF,01 x CSex(i) x CTerr(i) • If i is Female and Terr 01 → μi = BF,01 x 1.00 x 1.00

  20. Multiplicative Model • μi = exp(a0 + aSXS(i) + aTXT(i)) • μi = exp(a0) x exp(aSXS(i)) x exp( aTXT(i)) • i is Female → XS(i) = 0; Male →XS(i) = 1 • i is Terr 01 → XT(i) = 0; Terr 02 →XT(i) = 1

  21. Natural Log Link Function • ln(μi) = a0 + aSXS(i) + aTXT(i) • μi is in (0 , ∞ ) • ln(μi) is in ( - ∞ , ∞ )

  22. Poisson Distribution in Exponential Family

  23. Natural Log is Canonical Link for Poisson • θi = ln(μi) • θi= a0 + aSXS(i) + aTXT(i)

  24. Estimating Coefficients a1, a2, .., am • Classical linear regression uses least squares • GLMs use Maximum Likelihood Method

  25. Likelihood and Log Likelihood

  26. Find a0, aS, and aT for Poisson

  27. Iterative Numerical Procedure to Find ai’s • Use statistical package or actuarial software • Specify link function and distribution type

  28. Solution to Our Example • a0 = -.288 → exp(-.288) = .75 • aS = .262 → exp(.262) = 1.3 • aT = .095 → exp(.095) = 1.1 • μi = exp(a0) x exp(aSXS(i)) x exp( aTXT(i)) • μi = .75 x 1.3XS(i) x 1.1XT(i) • i is Male,Terr 01 → μi = .75 x 1.31 x 1.10

  29. Other Common Link Functions • Identity link: canonical link for Normal • Logit link ln[ μ/ (1- μ) ]: canonical link for Binomial • maps (0,1) onto ( -∞, ∞) • Reciprocal 1/μ: canonical link for Gamma • But, you do not have to match link and distribution. Choose link and distribution that make sense!

  30. Measuring Goodness of Fit • Deviance is measure of goodness of fit • Compare different models • Compare effect of dropping/adding Xij’s • Also called log likelihood ratio statistic

  31. More on Deviance

  32. Generalized Linear Models - GLMs • Response Y can be discrete or continuous • Y can be number of claims, probability of renewing, loss severity, loss ratio, etc. • Large and small policies can be put into one model. • Y can be nonlinear function of X’s • Measure goodness of fit using Deviance

More Related