### Generalized Linear Model (GzLM)

```Part V
The Generalized Linear Model
Chapter 16
Introduction
GENERAL LINEAR MODELS
ε ~ Normal
ANOVA
R: lm()
Multiple Linear Regression
t-test
Simple Linear Regression
ANCOVA
GENERALIZED LINEAR MODELS
Linear combination of parameters
R: glm()
Binomial
Poisson
Multinomial
GENERAL LINEAR MODELS
ε ~ Normal
ANOVA
R: lm()
Multiple Linear Regression
t-test
Simple Linear Regression
ANCOVA
Exponential
Negative Binomial
Inverse Gaussian
Gamma
Generalized Linear Model (GzLM)
Introduction
• Assumptions of GLM not always met using
biological data
Generalized Linear Model (GzLM)
Introduction
Generalized Linear Model (GzLM)
Introduction
Generalized Linear Model (GzLM)
Introduction
• Assumptions of GLM not always met using
biological data
– Transformations typically recommended
– We can randomize…
• Assumes parameter estimates (means, slopes, etc.) are
correct
– But a few large counts or many zeros will influence skew our
estimates
Generalized Linear Model (GzLM)
Introduction
Generalized Linear Model (GzLM)
Introduction
Generalized Linear Model (GzLM)
Introduction
• Assumptions of GLM not always met using
biological data
– Transformations typically recommended
– We can randomize…
• Assumes parameter estimates (means, slopes, etc.) are
correct
– But a few large counts or many zeros will influence skew our
estimates
– Best to use an appropriate error structure under
the Generalized Linear Model framework
Generalized Linear Model (GzLM)
Introduction
Poisson error
structure
Generalized Linear Model (GzLM)
Introduction
Binomial error
structure
Generalized Linear Model (GzLM)
•
•
•
•
Assumptions more evident
Decouples assumptions
Improves quality
Greater flexibility
Generalized Linear Model (GzLM)
•
•
•
•
Assumptions more evident
Decouples assumptions
Improves quality
Greater flexibility
Part V
The Generalized Linear Model
Chapter 16.1
Goodness of Fit
Goodness of Fit - The Chi-square statistic
• Have to learn a new concept to apply GzLM:
– Goodness of Fit
• Chi-square statistic
• G-statistic
Classic Chi-square
Statistic Example
Gregor Mendel’s Peas
Purple:
White:
χ2
=
−

2
Classic Chi-square
Statistic Example
Gregor Mendel’s Peas
χ2 = 0.3907
df = 1
p = 0.532
Classic Chi-square
Statistic Example
Gregor Mendel’s Peas
χ2 = 0.3907
df = 1
p = 0.532
• Deviation from genetic model
(3:1) not significant
Goodness of Fit - The G-statistic
• Can deal with complex models
• Based in likelihood
Goodness of Fit - The G-statistic
Smaller deviation  smaller G-statistic
G-statistic 
 p-value = 0.53
Improvement in Fit - ΔG
• Next time we will…
– Compare G values (ΔG) to assess improvement in
fit of one model over another
```