Generalized Linear Model
Generalized Linear Model A Unified Theory Various responses Binary Ordinal Count Polytomous
Generalized Linear Model A Unified Theory
Mean Structure Ordinary Linear Model Generalized Linear Model
Link Functions Link function: Log link Logit link Log-log link Probit link
Logistic Regression Model Link functions
Poisson Regression Model Link Functions Example: Auto Insurance
Ordinal Regression Model Link Functions
Polytomous Regression Model Link Functions
Polytomous Regression Properties Therefore,
Deviance Likelihood function Deviance Objective: Measuring discrepancy (like residual sum of squares)
Normal Example Likelihood function Deviance
Poisson Example Likelihood function Deviance
Analysis of Deviance Model d.f. Discrepancy s.s. 1 11 1000 A 8 500 3 A+B 6 200 300 2 A+B+A*B
Pearson Residuals Define where Example: Normal Distribution
Deviance Residual Deviance Define Example: Normal Distribution
Logistic Regression
Binary Responses Example Properties Credit approval, employment Response can only take one of the two possible outcomes Covariates could be anything
Logistic Regression Model Link functions
Case Study Objective: Comparing site preference for lizard Data Source: Fienberg (1970b) Variables Response: Site preference (Sunny/Shady). Discretized perch height and diameter Time of the data (Early, Mid, Late) Species: Grahami and Opalinus
Statistical Model
SAS Program proc genmod data=A0; class site diameter height time species; freq number; model species = diameter height time site /dist=bin link=logit p r type3; run;
Logit Link
Probit Link
Poisson Regression
Count Responses Example Properties Auto accidents, service request Properties Constant arriving rate Independent waiting time Waiting time is memorylessness Then, the number of requests per unit time has to be a Poisson random variable
Poisson Distribution Probability Density Function Mean and Variance
Normalization Transformation Define transformation Limiting distribution (why?)
Variance Stabilization Transformation Define It can be obtained then Therefore
Poisson Regression Model Link Functions Example: Auto Insurance
Case Study Objective: What cause the wave damage to cargo ships Data Source: Lloyd’s Register of Shipping by J. Crilley and L. N. Heminway Variables Ship type: A – E. Year of construction: 60-64, 65-69, 70-74,75-79 Period of operation: 60-74, 75-79 Aggregate months services
Statistical Model Log(expected number of incidents) = log(aggregate month services) + (effect due to ship type) + (effect due to year of construction) + (effect due to service period)
SAS Program proc genmod data=A0; class type year period; model number = type year period logMonth/dist=P link=log p r type3; run;
Ordinal Regression
Ordinal Responses Example Properties Preference data No numerical meaning Order dose matters Consecutive categories can be collapsed into one
Ordinal Regression Model Link Functions
Case Study Objective: Which cheese customers like most? Data Source: Experiment done by Dr. Graeme Newell Variables Cheese type: A – D. Response: 1 – 9 with larger value = better
Statistical Model
SAS Program proc genmod data=A0; class type; freq total; model pref = type/dist=multinomial link=cumlogit p r type3; run;
Progress Report Due: Next week before the class Requirement: Electronic submission by e-mail In one zipped file, no other format will be accepted The zip file should contain: Finalize project proposal in WORD or PDF format Cleaned data set: In SAS format Preliminary/Descriptive Analysis Report Please refer to the sample directory structure on server
New Project A animal study Requirement Four treatment groups with one is control Ordinal responses were measure on 17 consecutive days Question: Is there a treatment effect? Requirement Formal report as before Due: In two weeks (Dec. 13th)