SlideShare ist ein Scribd-Unternehmen logo
1 von 39
Downloaden Sie, um offline zu lesen
Denitions Estimation Inference Challenges  open questions References
Generalized linear mixed model discussion
Ben Bolker
McMaster University, Mathematics  Statistics and Biology
25 April 2014
Denitions Estimation Inference Challenges  open questions References
Acknowledgments
lme4: Doug Bates, Martin
Mächler, Steve Walker
Data: Josh Banta, Adrian Stier,
Sea McKeon, David Julian,
Jada-Simone White
NSERC (Discovery)
SHARCnet
Denitions Estimation Inference Challenges  open questions References
Outline
1 Examples and denitions
2 Estimation
Overview
Methods
3 Inference
4 Challenges  open questions
Denitions Estimation Inference Challenges  open questions References
Outline
1 Examples and denitions
2 Estimation
Overview
Methods
3 Inference
4 Challenges  open questions
Denitions Estimation Inference Challenges  open questions References
(Generalized) linear mixed models
(G)LMMs: a statistical modeling framework incorporating:
Linear combinations of categorical and continuous
predictors, and interactions
Response distributions in the exponential family
(binomial, Poisson, and extensions)
Any smooth, monotonic link function
(e.g. logistic, exponential models)
Flexible combinations of blocking factors
(clustering; random eects)
Denitions Estimation Inference Challenges  open questions References
(Generalized) linear mixed models
(G)LMMs: a statistical modeling framework incorporating:
Linear combinations of categorical and continuous
predictors, and interactions
Response distributions in the exponential family
(binomial, Poisson, and extensions)
Any smooth, monotonic link function
(e.g. logistic, exponential models)
Flexible combinations of blocking factors
(clustering; random eects)
Denitions Estimation Inference Challenges  open questions References
(Generalized) linear mixed models
(G)LMMs: a statistical modeling framework incorporating:
Linear combinations of categorical and continuous
predictors, and interactions
Response distributions in the exponential family
(binomial, Poisson, and extensions)
Any smooth, monotonic link function
(e.g. logistic, exponential models)
Flexible combinations of blocking factors
(clustering; random eects)
Denitions Estimation Inference Challenges  open questions References
Coral protection by symbionts
(McKeon et al., 2012)
none shrimp crabs both
Number of predation events
Symbionts
Numberofblocks
0
2
4
6
8
10
1
2
0
1
2
0
2
0
1
2
Denitions Estimation Inference Challenges  open questions References
Environmental stress: Glycera cell survival
(D. Julian unpubl.)
H2S
Copper
0
33.3
66.6
133.3
0 0.03 0.1 0.32
Osm=12.8
Normoxia
Osm=22.4
Normoxia
0 0.03 0.1 0.32
Osm=32
Normoxia
Osm=41.6
Normoxia
0 0.03 0.1 0.32
Osm=51.2
Normoxia
Osm=12.8
Anoxia
0 0.03 0.1 0.32
Osm=22.4
Anoxia
Osm=32
Anoxia
0 0.03 0.1 0.32
Osm=41.6
Anoxia
0
33.3
66.6
133.3
Osm=51.2
Anoxia
0.0
0.2
0.4
0.6
0.8
1.0
Denitions Estimation Inference Challenges  open questions References
Arabidopsis response to fertilization  clipping
(Banta et al., 2010)
panel: nutrient, color: genotypeLog(1+fruitset)
0
1
2
3
4
5
unclipped clipped
qqqqq q
qq
q
qq
q
q
q
q
q
qq
q
q
qq
q
q
q
q
qqq q
q q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
qq
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
qq
q
q
q
q
q
q q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q q
q
q
q
q
q
q
q
q
q
qqq qq q
q
qq
q
qq
q
qq
q
q
q
q
qq q
q
q
q
q
q
q qqq qqq qqq qqq qq qq qq q
q
q
q
q qqq qqqq
q
q
q
qq
q
q
q q
q
q
q
qqqqqq qq
q
q
q q
q
q
q q
q
q
q
q
q
:nutrient 1
unclipped clipped
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
qq
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q q
q
q
q
q qq
q
q
q
q
q
q
q
q
qq
q
qq
q
q
q
q
q
q
q
qq
q
qq
q
q
q
q
q
q
q
q
qq
q
q
q q
q
q
q
qq
q
q
q
q
q
q
q
q
q
q
qqqq qq qqq qqqq q
q
q
qq
q
q
q
q
q
q
qqqqqqq qqq qq
q
q
q
q
q
q
q
q
q
q
q
q
q
qqqq
q
q
qqqqq
q
qq
q
q
q
q
q
q
q
q
q
q
:nutrient 8
Denitions Estimation Inference Challenges  open questions References
Coral demography
(J.-S. White unpubl.)
Before Experimental
q
q
q q q q
qq
q
q q
q q
q
q
qq qq
q
qq q q
q
qq qq
q
qq
q
q q
qq
q
q
q
q
q
q
q
q
q
qq
q
q
q q
q
q
q
q
q q
q
q
q
q
q q
q
qqq
qq
q
q
qqqq
q qq q
q
q
q
q qq q
q
q
q
qq
q
q
q
q q q
q
q q
q q
q
q qqq qqq q
q
q
q
q
q
q
qq q
q
q
q
q
q qqq
q
q
q
q
q
q
q
q qq qqq
q
q
q
qqq
q
q
q
qq
q
qq
qq
q
qqq q
qq
qq qq qq
q
q
q
qq
q
qqq qq
q
q
q q
q
q q
q
q
q0.00
0.25
0.50
0.75
1.00
0 10 20 30 40 50 0 10 20 30 40 50
Previous size (cm)
Mortalityprobability
Treatment
q
q
Present
Removed
Denitions Estimation Inference Challenges  open questions References
Technical denition
Yi
response
∼
conditional
distribution
Distr (g−1(ηi )
inverse
link
function
, φ
scale
parameter
)
η
linear
predictor
= Xβ
xed
eects
+ Zb
random
eects
b
conditional
modes
∼ MVN(0, Σ(θ)
variance-
covariance
matrix
)
Denitions Estimation Inference Challenges  open questions References
What are random eects?
a way to account for among-individual, within-block correlation
a compromise between complete pooling (σ2
among = 0) and
xed eects (σ2
among → ∞)
levels selected at random from a larger population
a way do to shrinkage estimation/share information among
levels
a way to estimate variability among levels
a way to allow predictions on unmeasured levels
Denitions Estimation Inference Challenges  open questions References
What are random eects?
a way to account for among-individual, within-block correlation
a compromise between complete pooling (σ2
among = 0) and
xed eects (σ2
among → ∞)
levels selected at random from a larger population
a way do to shrinkage estimation/share information among
levels
a way to estimate variability among levels
a way to allow predictions on unmeasured levels
Denitions Estimation Inference Challenges  open questions References
What are random eects?
a way to account for among-individual, within-block correlation
a compromise between complete pooling (σ2
among = 0) and
xed eects (σ2
among → ∞)
levels selected at random from a larger population
a way do to shrinkage estimation/share information among
levels
a way to estimate variability among levels
a way to allow predictions on unmeasured levels
Denitions Estimation Inference Challenges  open questions References
What are random eects?
a way to account for among-individual, within-block correlation
a compromise between complete pooling (σ2
among = 0) and
xed eects (σ2
among → ∞)
levels selected at random from a larger population
a way do to shrinkage estimation/share information among
levels
a way to estimate variability among levels
a way to allow predictions on unmeasured levels
Denitions Estimation Inference Challenges  open questions References
What are random eects?
a way to account for among-individual, within-block correlation
a compromise between complete pooling (σ2
among = 0) and
xed eects (σ2
among → ∞)
levels selected at random from a larger population
a way do to shrinkage estimation/share information among
levels
a way to estimate variability among levels
a way to allow predictions on unmeasured levels
Denitions Estimation Inference Challenges  open questions References
What are random eects?
a way to account for among-individual, within-block correlation
a compromise between complete pooling (σ2
among = 0) and
xed eects (σ2
among → ∞)
levels selected at random from a larger population
a way do to shrinkage estimation/share information among
levels
a way to estimate variability among levels
a way to allow predictions on unmeasured levels
Denitions Estimation Inference Challenges  open questions References
Outline
1 Examples and denitions
2 Estimation
Overview
Methods
3 Inference
4 Challenges  open questions
Denitions Estimation Inference Challenges  open questions References
Maximum likelihood estimation
L(Yi |θ, β)
likelihood
= · · · L(Yi |β, b)
data|random eects
× L(b|Σ(θ))
random eects
db
Best t is a compromise between two components
(consistency of data with xed eects and conditional modes;
consistency of random eect with RE distribution)
Denitions Estimation Inference Challenges  open questions References
Integrated (marginal) likelihood
−10 −5 0 5 10
0.0
0.2
0.4
0.6
0.8
1.0
conditional mode value (u)
Scaledprobability
L(b|σ2
)
L(x|b, β)
Lprod
Denitions Estimation Inference Challenges  open questions References
Shrinkage: Arabidopsis conditional modes
q q
q
q
q
q
q q q q q q q q q q q q q q q q q q
Genotype
Mean(log)fruitset
0 5 10 15 20 25
−15
−3
0
3
q q q
q
q
q
q q q q q q q q q q q q q q q q q q
3 2 10
8
10
4
3 9 9 4 6 4 2 6 10 5 7 9 4 9 11 2 5 5
Denitions Estimation Inference Challenges  open questions References
Estimation methods
deterministic : various approximate integrals (Breslow, 2004) . . .
stochastic (Monte Carlo): frequentist and Bayesian (Booth and
Hobert, 1999; Ponciano et al., 2009; Sung, 2007)
Denitions Estimation Inference Challenges  open questions References
Deterministic approaches
PQL fast and biased, especially for binary/low-count data:
(MASS:glmmPQL)
Laplace intermediate (lme4:glmer, glmmML, glmmADMB,
R2ADMB (AD Model Builder))
Gauss-Hermite quadrature slow but accurate (lme4:glmer,
glmmML, repeated)
INLA Bayesian, very exible: INLA
General trade-o between exibility (ADMB/glmmADMB) and
eciency (lme4)
Denitions Estimation Inference Challenges  open questions References
Stochastic approaches
Mostly Bayesians (Bayesian computation handles
high-dimensional integration)
various avours: Gibbs sampling, MCMC, MCEM, etc.
generally slower but more exible
simplies many inferential problems
must specify priors, assess convergence/error
specialized: glmmAK, MCMCglmm (Hadeld, 2010), bernor
general: glmmBUGS, R2WinBUGS, BRugs (WinBUGS/OpenBUGS),
R2jags, rjags (JAGS), glmer2stan, Stan
Denitions Estimation Inference Challenges  open questions References
Estimation: example (McKeon et al., 2012)
Log−odds of predation
−6 −4 −2 0 2
Symbiont
Crab vs. Shrimp
Added symbiont
q
q
q
q
q
q
q
q
q
q
q
q
q
q
q
GLM (fixed)
GLM (pooled)
PQL
Laplace
AGQ
Denitions Estimation Inference Challenges  open questions References
Outline
1 Examples and denitions
2 Estimation
Overview
Methods
3 Inference
4 Challenges  open questions
Denitions Estimation Inference Challenges  open questions References
Wald tests
Wald tests (e.g. typical results of summary)
based on information matrix
assume quadratic log-likelihood surface
exact for regular linear models;
only asymptotically OK for GLM(M)s
computationally cheap
approximation is sometimes awful (Hauck-Donner eect)
Denitions Estimation Inference Challenges  open questions References
2D proles for coral predation
Scatter Plot Matrix
.sig01
2 4 6 8 101214
−3
−2
−1
0
(Intercept)
0
5
10
15
10 15
0 1 2 3
tttcrabs
−10
−8
−6
−4
−2
0
−4 −2 0
0 1 2 3
tttshrimp
−10
−8
−6
−4
−2 −6 −4 −2
0 1 2 3
tttboth
−12
−10
−8
−6
−4
−2
0 1 2 3
Denitions Estimation Inference Challenges  open questions References
Likelihood ratio tests
better, but still have to deal with two nite-size problems:
denominator degrees of freedom (when estimating scale)
numerator is only asymptotically χ2 anyway (Bartlett
corrections)
Kenward-Roger correction? (Stroup, 2014)
Prole condence intervals: moderately expensive/fragile
Denitions Estimation Inference Challenges  open questions References
Parametric bootstrapping
t null model to data
simulate data from null model
t null and working model, compute likelihood dierence
repeat to estimate null distribution
should be OK but ??? not well tested
(assumes estimated parameters are suciently good)
Denitions Estimation Inference Challenges  open questions References
Parametric bootstrap results
True p value
Inferredpvalue
0.02
0.04
0.06
0.08
0.02 0.06
Osm Cu
H2S
0.02 0.06
0.02
0.04
0.06
0.08
Anoxia
Denitions Estimation Inference Challenges  open questions References
Bayesian approaches
If we have a good sample from the posterior distribution
(Markov chains have converged etc. etc.) we get most of the
inferences we want for free by summarizing the marginal
posteriors
post hoc Bayesian can work, but mode at zero causes
problems
Denitions Estimation Inference Challenges  open questions References
Outline
1 Examples and denitions
2 Estimation
Overview
Methods
3 Inference
4 Challenges  open questions
Denitions Estimation Inference Challenges  open questions References
On beyond R
Julia: MixedModels package
SAS: PROC MIXED, NLMIXED
AS-REML
Stata (GLLAMM, xtmelogit)
AD Model Builder
HLM, MLWiN
Denitions Estimation Inference Challenges  open questions References
Challenges
Small/medium data: inference, singular ts (blme, MCMCglmm)
Big data: speed!
Worst case: large n, small N (e.g. telemetry/genomics)
Model diagnosis
Condence intervals accounting for uncertainty in variances
See also: http://rpubs.com/bbolker/glmmchapter, https:
//groups.nceas.ucsb.edu/non-linear-modeling/projects
Denitions Estimation Inference Challenges  open questions References
What about space?
Sometimes blocks are spatial partitions (sites, zip codes,
states)
O-the-shelf methods for true spatial GLMMs?
(Dormann et al., 2007)
Correlation of residuals or conditional modes?
INLA; GeoBUGS; ADMB
lme4: hacking Z: pedigrees, moving average, CAR models?
lme4: flexLambda branch
methods also apply to temporal, phylogenetic correlations
(Ives and Helmus, 2011)
Denitions Estimation Inference Challenges  open questions References
Next steps
Complex random eects:
regularization, model selection, penalized methods
(lasso/fence)
Flexible correlation and variance structures
Flexible/nonparametric random eects distributions
hybrid  improved MCMC methods
Reliable assessment of out-of-sample performance
Denitions Estimation Inference Challenges  open questions References
Banta, J.A., Stevens, M.H.H., and Pigliucci, M., 2010. Oikos, 119(2):359369. ISSN 1600-0706.
doi:10.1111/j.1600-0706.2009.17726.x.
Booth, J.G. and Hobert, J.P., 1999. Journal of the Royal Statistical Society. Series B, 61(1):265285.
doi:10.1111/1467-9868.00176.
Breslow, N.E., 2004. In D.Y. Lin and P.J. Heagerty, editors, Proceedings of the second Seattle
symposium in biostatistics: Analysis of correlated data, pages 122. Springer. ISBN 0387208623.
Dormann, C.F., McPherson, J.M., et al., 2007. Ecography, 30(5):609628.
doi:10.1111/j.2007.0906-7590.05171.x.
Hadeld, J.D., 2010. Journal of Statistical Software, 33(2):122. ISSN 1548-7660.
Ives, A.R. and Helmus, M.R., 2011. Ecological Monographs, 81(3):511525. ISSN 0012-9615.
doi:10.1890/10-1264.1.
McKeon, C.S., Stier, A., et al., 2012. Oecologia, 169(4):10951103. ISSN 0029-8549.
doi:10.1007/s00442-012-2275-2.
Ponciano, J.M., Taper, M.L., et al., 2009. Ecology, 90(2):356362. ISSN 0012-9658.
Stroup, W.W., 2014. Agronomy Journal, 106:117. doi:10.2134/agronj2013.0342.
Sung, Y.J., 2007. The Annals of Statistics, 35(3):9901011. ISSN 0090-5364.
doi:10.1214/009053606000001389.

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (9)

Two-way Mixed Design with SPSS
Two-way Mixed Design with SPSSTwo-way Mixed Design with SPSS
Two-way Mixed Design with SPSS
 
Hybrid Block Method for the Solution of First Order Initial Value Problems of...
Hybrid Block Method for the Solution of First Order Initial Value Problems of...Hybrid Block Method for the Solution of First Order Initial Value Problems of...
Hybrid Block Method for the Solution of First Order Initial Value Problems of...
 
Perspective of feature selection in bioinformatics
Perspective of feature selection in bioinformaticsPerspective of feature selection in bioinformatics
Perspective of feature selection in bioinformatics
 
PresTrojan0_1212
PresTrojan0_1212PresTrojan0_1212
PresTrojan0_1212
 
PPI, GCA, and DCM in resting-state
PPI, GCA, and DCM in resting-statePPI, GCA, and DCM in resting-state
PPI, GCA, and DCM in resting-state
 
Contingency Tables
Contingency TablesContingency Tables
Contingency Tables
 
Chi square test
Chi square test Chi square test
Chi square test
 
Word Frequency Dominance and L2 Word Recognition
Word Frequency Dominance and L2 Word RecognitionWord Frequency Dominance and L2 Word Recognition
Word Frequency Dominance and L2 Word Recognition
 
Chapter 5 t-test
Chapter 5 t-testChapter 5 t-test
Chapter 5 t-test
 

Andere mochten auch (10)

Bolker esa2014
Bolker esa2014Bolker esa2014
Bolker esa2014
 
evolution of virulence: devil in the details
evolution of virulence: devil in the detailsevolution of virulence: devil in the details
evolution of virulence: devil in the details
 
Threads 2013
Threads 2013Threads 2013
Threads 2013
 
Google lme4
Google lme4Google lme4
Google lme4
 
Davis eco-evo virulence
Davis eco-evo virulenceDavis eco-evo virulence
Davis eco-evo virulence
 
virulence evolution (IGERT symposium)
virulence evolution (IGERT symposium)virulence evolution (IGERT symposium)
virulence evolution (IGERT symposium)
 
Waterloo GLMM talk
Waterloo GLMM talkWaterloo GLMM talk
Waterloo GLMM talk
 
model complexity and model choice for animal movement models
model complexity and model choice for animal movement modelsmodel complexity and model choice for animal movement models
model complexity and model choice for animal movement models
 
intro to knitr with RStudio
intro to knitr with RStudiointro to knitr with RStudio
intro to knitr with RStudio
 
model complexity and model choice for animal movement models
model complexity and model choice for animal movement modelsmodel complexity and model choice for animal movement models
model complexity and model choice for animal movement models
 

Ähnlich wie Igert glmm

6Categorical data analysis presentation.pdf
6Categorical data analysis presentation.pdf6Categorical data analysis presentation.pdf
6Categorical data analysis presentation.pdf
MitikuTeka1
 
Intro to Model Selection
Intro to Model SelectionIntro to Model Selection
Intro to Model Selection
chenhm
 
2010 smg training_cardiff_day2_session2_dias
2010 smg training_cardiff_day2_session2_dias2010 smg training_cardiff_day2_session2_dias
2010 smg training_cardiff_day2_session2_dias
rgveroniki
 

Ähnlich wie Igert glmm (20)

ECONOMETRICS I ASA
ECONOMETRICS I ASAECONOMETRICS I ASA
ECONOMETRICS I ASA
 
Ch01 03
Ch01 03Ch01 03
Ch01 03
 
Open source GLMM tools: Concordia
Open source GLMM tools: ConcordiaOpen source GLMM tools: Concordia
Open source GLMM tools: Concordia
 
Importance of X-STR Linkage Groups in the Establishment of Maternal Relatedne...
Importance of X-STR Linkage Groups in the Establishment of Maternal Relatedne...Importance of X-STR Linkage Groups in the Establishment of Maternal Relatedne...
Importance of X-STR Linkage Groups in the Establishment of Maternal Relatedne...
 
Ch01_03.ppt
Ch01_03.pptCh01_03.ppt
Ch01_03.ppt
 
Dealing with Constraints in Estimation of Distribution Algorithms
Dealing with Constraints in Estimation of Distribution AlgorithmsDealing with Constraints in Estimation of Distribution Algorithms
Dealing with Constraints in Estimation of Distribution Algorithms
 
Probability distribution Function & Decision Trees in machine learning
Probability distribution Function  & Decision Trees in machine learningProbability distribution Function  & Decision Trees in machine learning
Probability distribution Function & Decision Trees in machine learning
 
Business research methods 2
Business research methods 2Business research methods 2
Business research methods 2
 
6Categorical data analysis presentation.pdf
6Categorical data analysis presentation.pdf6Categorical data analysis presentation.pdf
6Categorical data analysis presentation.pdf
 
Quantitative Analysis: Conducting, Interpreting, & Writing
Quantitative Analysis: Conducting, Interpreting, & WritingQuantitative Analysis: Conducting, Interpreting, & Writing
Quantitative Analysis: Conducting, Interpreting, & Writing
 
SimpleLinearRegressionAnalysisWithExamples.ppt
SimpleLinearRegressionAnalysisWithExamples.pptSimpleLinearRegressionAnalysisWithExamples.ppt
SimpleLinearRegressionAnalysisWithExamples.ppt
 
Linear regression.ppt
Linear regression.pptLinear regression.ppt
Linear regression.ppt
 
lecture13.ppt
lecture13.pptlecture13.ppt
lecture13.ppt
 
lecture13.ppt
lecture13.pptlecture13.ppt
lecture13.ppt
 
Slideset Simple Linear Regression models.ppt
Slideset Simple Linear Regression models.pptSlideset Simple Linear Regression models.ppt
Slideset Simple Linear Regression models.ppt
 
lecture13.ppt
lecture13.pptlecture13.ppt
lecture13.ppt
 
lecture13.ppt
lecture13.pptlecture13.ppt
lecture13.ppt
 
Intro to Model Selection
Intro to Model SelectionIntro to Model Selection
Intro to Model Selection
 
08 Inference for Networks – DYAD Model Overview (2017)
08 Inference for Networks – DYAD Model Overview (2017)08 Inference for Networks – DYAD Model Overview (2017)
08 Inference for Networks – DYAD Model Overview (2017)
 
2010 smg training_cardiff_day2_session2_dias
2010 smg training_cardiff_day2_session2_dias2010 smg training_cardiff_day2_session2_dias
2010 smg training_cardiff_day2_session2_dias
 

Mehr von Ben Bolker

MBRS detectability talk
MBRS detectability talkMBRS detectability talk
MBRS detectability talk
Ben Bolker
 
MBI intro to spatial models
MBI intro to spatial modelsMBI intro to spatial models
MBI intro to spatial models
Ben Bolker
 
Harvard Forest GLMM talk
Harvard Forest GLMM talkHarvard Forest GLMM talk
Harvard Forest GLMM talk
Ben Bolker
 
ESA 2011 pines/spatial talk
ESA 2011 pines/spatial talkESA 2011 pines/spatial talk
ESA 2011 pines/spatial talk
Ben Bolker
 
unmarked individuals: Guelph
unmarked individuals: Guelphunmarked individuals: Guelph
unmarked individuals: Guelph
Ben Bolker
 

Mehr von Ben Bolker (12)

Ecological synthesis across scales: West Nile virus in individuals and commun...
Ecological synthesis across scales: West Nile virus in individuals and commun...Ecological synthesis across scales: West Nile virus in individuals and commun...
Ecological synthesis across scales: West Nile virus in individuals and commun...
 
Fundamental principles (?) of biological data
Fundamental principles (?) of biological dataFundamental principles (?) of biological data
Fundamental principles (?) of biological data
 
MBRS detectability talk
MBRS detectability talkMBRS detectability talk
MBRS detectability talk
 
Disease-induced extinction
Disease-induced extinctionDisease-induced extinction
Disease-induced extinction
 
Zif bolker_w2
Zif bolker_w2Zif bolker_w2
Zif bolker_w2
 
Trondheim glmm
Trondheim glmmTrondheim glmm
Trondheim glmm
 
MBI intro to spatial models
MBI intro to spatial modelsMBI intro to spatial models
MBI intro to spatial models
 
Harvard Forest GLMM talk
Harvard Forest GLMM talkHarvard Forest GLMM talk
Harvard Forest GLMM talk
 
ESA 2011 pines/spatial talk
ESA 2011 pines/spatial talkESA 2011 pines/spatial talk
ESA 2011 pines/spatial talk
 
open-source GLMM tools
open-source GLMM toolsopen-source GLMM tools
open-source GLMM tools
 
unmarked individuals: Guelph
unmarked individuals: Guelphunmarked individuals: Guelph
unmarked individuals: Guelph
 
GLMs and extensions in R
GLMs and extensions in RGLMs and extensions in R
GLMs and extensions in R
 

Kürzlich hochgeladen

development of diagnostic enzyme assay to detect leuser virus
development of diagnostic enzyme assay to detect leuser virusdevelopment of diagnostic enzyme assay to detect leuser virus
development of diagnostic enzyme assay to detect leuser virus
NazaninKarimi6
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Kürzlich hochgeladen (20)

development of diagnostic enzyme assay to detect leuser virus
development of diagnostic enzyme assay to detect leuser virusdevelopment of diagnostic enzyme assay to detect leuser virus
development of diagnostic enzyme assay to detect leuser virus
 
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
 
Justdial Call Girls In Indirapuram, Ghaziabad, 8800357707 Escorts Service
Justdial Call Girls In Indirapuram, Ghaziabad, 8800357707 Escorts ServiceJustdial Call Girls In Indirapuram, Ghaziabad, 8800357707 Escorts Service
Justdial Call Girls In Indirapuram, Ghaziabad, 8800357707 Escorts Service
 
Connaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verified
Connaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verifiedConnaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verified
Connaught Place, Delhi Call girls :8448380779 Model Escorts | 100% verified
 
Pulmonary drug delivery system M.pharm -2nd sem P'ceutics
Pulmonary drug delivery system M.pharm -2nd sem P'ceuticsPulmonary drug delivery system M.pharm -2nd sem P'ceutics
Pulmonary drug delivery system M.pharm -2nd sem P'ceutics
 
Zoology 5th semester notes( Sumit_yadav).pdf
Zoology 5th semester notes( Sumit_yadav).pdfZoology 5th semester notes( Sumit_yadav).pdf
Zoology 5th semester notes( Sumit_yadav).pdf
 
FAIRSpectra - Enabling the FAIRification of Analytical Science
FAIRSpectra - Enabling the FAIRification of Analytical ScienceFAIRSpectra - Enabling the FAIRification of Analytical Science
FAIRSpectra - Enabling the FAIRification of Analytical Science
 
9654467111 Call Girls In Raj Nagar Delhi Short 1500 Night 6000
9654467111 Call Girls In Raj Nagar Delhi Short 1500 Night 60009654467111 Call Girls In Raj Nagar Delhi Short 1500 Night 6000
9654467111 Call Girls In Raj Nagar Delhi Short 1500 Night 6000
 
GBSN - Microbiology (Unit 3)
GBSN - Microbiology (Unit 3)GBSN - Microbiology (Unit 3)
GBSN - Microbiology (Unit 3)
 
COST ESTIMATION FOR A RESEARCH PROJECT.pptx
COST ESTIMATION FOR A RESEARCH PROJECT.pptxCOST ESTIMATION FOR A RESEARCH PROJECT.pptx
COST ESTIMATION FOR A RESEARCH PROJECT.pptx
 
Dubai Call Girls Beauty Face Teen O525547819 Call Girls Dubai Young
Dubai Call Girls Beauty Face Teen O525547819 Call Girls Dubai YoungDubai Call Girls Beauty Face Teen O525547819 Call Girls Dubai Young
Dubai Call Girls Beauty Face Teen O525547819 Call Girls Dubai Young
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
module for grade 9 for distance learning
module for grade 9 for distance learningmodule for grade 9 for distance learning
module for grade 9 for distance learning
 
GBSN - Biochemistry (Unit 1)
GBSN - Biochemistry (Unit 1)GBSN - Biochemistry (Unit 1)
GBSN - Biochemistry (Unit 1)
 
GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)
 
Molecular markers- RFLP, RAPD, AFLP, SNP etc.
Molecular markers- RFLP, RAPD, AFLP, SNP etc.Molecular markers- RFLP, RAPD, AFLP, SNP etc.
Molecular markers- RFLP, RAPD, AFLP, SNP etc.
 
PSYCHOSOCIAL NEEDS. in nursing II sem pptx
PSYCHOSOCIAL NEEDS. in nursing II sem pptxPSYCHOSOCIAL NEEDS. in nursing II sem pptx
PSYCHOSOCIAL NEEDS. in nursing II sem pptx
 
Grade 7 - Lesson 1 - Microscope and Its Functions
Grade 7 - Lesson 1 - Microscope and Its FunctionsGrade 7 - Lesson 1 - Microscope and Its Functions
Grade 7 - Lesson 1 - Microscope and Its Functions
 
300003-World Science Day For Peace And Development.pptx
300003-World Science Day For Peace And Development.pptx300003-World Science Day For Peace And Development.pptx
300003-World Science Day For Peace And Development.pptx
 
Site Acceptance Test .
Site Acceptance Test                    .Site Acceptance Test                    .
Site Acceptance Test .
 

Igert glmm

  • 1. Denitions Estimation Inference Challenges open questions References Generalized linear mixed model discussion Ben Bolker McMaster University, Mathematics Statistics and Biology 25 April 2014
  • 2. Denitions Estimation Inference Challenges open questions References Acknowledgments lme4: Doug Bates, Martin Mächler, Steve Walker Data: Josh Banta, Adrian Stier, Sea McKeon, David Julian, Jada-Simone White NSERC (Discovery) SHARCnet
  • 3. Denitions Estimation Inference Challenges open questions References Outline 1 Examples and denitions 2 Estimation Overview Methods 3 Inference 4 Challenges open questions
  • 4. Denitions Estimation Inference Challenges open questions References Outline 1 Examples and denitions 2 Estimation Overview Methods 3 Inference 4 Challenges open questions
  • 5. Denitions Estimation Inference Challenges open questions References (Generalized) linear mixed models (G)LMMs: a statistical modeling framework incorporating: Linear combinations of categorical and continuous predictors, and interactions Response distributions in the exponential family (binomial, Poisson, and extensions) Any smooth, monotonic link function (e.g. logistic, exponential models) Flexible combinations of blocking factors (clustering; random eects)
  • 6. Denitions Estimation Inference Challenges open questions References (Generalized) linear mixed models (G)LMMs: a statistical modeling framework incorporating: Linear combinations of categorical and continuous predictors, and interactions Response distributions in the exponential family (binomial, Poisson, and extensions) Any smooth, monotonic link function (e.g. logistic, exponential models) Flexible combinations of blocking factors (clustering; random eects)
  • 7. Denitions Estimation Inference Challenges open questions References (Generalized) linear mixed models (G)LMMs: a statistical modeling framework incorporating: Linear combinations of categorical and continuous predictors, and interactions Response distributions in the exponential family (binomial, Poisson, and extensions) Any smooth, monotonic link function (e.g. logistic, exponential models) Flexible combinations of blocking factors (clustering; random eects)
  • 8. Denitions Estimation Inference Challenges open questions References Coral protection by symbionts (McKeon et al., 2012) none shrimp crabs both Number of predation events Symbionts Numberofblocks 0 2 4 6 8 10 1 2 0 1 2 0 2 0 1 2
  • 9. Denitions Estimation Inference Challenges open questions References Environmental stress: Glycera cell survival (D. Julian unpubl.) H2S Copper 0 33.3 66.6 133.3 0 0.03 0.1 0.32 Osm=12.8 Normoxia Osm=22.4 Normoxia 0 0.03 0.1 0.32 Osm=32 Normoxia Osm=41.6 Normoxia 0 0.03 0.1 0.32 Osm=51.2 Normoxia Osm=12.8 Anoxia 0 0.03 0.1 0.32 Osm=22.4 Anoxia Osm=32 Anoxia 0 0.03 0.1 0.32 Osm=41.6 Anoxia 0 33.3 66.6 133.3 Osm=51.2 Anoxia 0.0 0.2 0.4 0.6 0.8 1.0
  • 10. Denitions Estimation Inference Challenges open questions References Arabidopsis response to fertilization clipping (Banta et al., 2010) panel: nutrient, color: genotypeLog(1+fruitset) 0 1 2 3 4 5 unclipped clipped qqqqq q qq q qq q q q q q qq q q qq q q q q qqq q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q qq q q q q q q q q qq q q q qq q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q qq q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q qqq qq q q qq q qq q qq q q q q qq q q q q q q q qqq qqq qqq qqq qq qq qq q q q q q qqq qqqq q q q qq q q q q q q q qqqqqq qq q q q q q q q q q q q q q :nutrient 1 unclipped clipped q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q qq q q q q q q q q q q q q q q qq q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q qq q q q q q qq q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q qq q qq q q q q q q q qq q qq q q q q q q q q qq q q q q q q q qq q q q q q q q q q q qqqq qq qqq qqqq q q q qq q q q q q q qqqqqqq qqq qq q q q q q q q q q q q q q qqqq q q qqqqq q qq q q q q q q q q q q :nutrient 8
  • 11. Denitions Estimation Inference Challenges open questions References Coral demography (J.-S. White unpubl.) Before Experimental q q q q q q qq q q q q q q q qq qq q qq q q q qq qq q qq q q q qq q q q q q q q q q qq q q q q q q q q q q q q q q q q q qqq qq q q qqqq q qq q q q q q qq q q q q qq q q q q q q q q q q q q q qqq qqq q q q q q q q qq q q q q q q qqq q q q q q q q q qq qqq q q q qqq q q q qq q qq qq q qqq q qq qq qq qq q q q qq q qqq qq q q q q q q q q q q0.00 0.25 0.50 0.75 1.00 0 10 20 30 40 50 0 10 20 30 40 50 Previous size (cm) Mortalityprobability Treatment q q Present Removed
  • 12. Denitions Estimation Inference Challenges open questions References Technical denition Yi response ∼ conditional distribution Distr (g−1(ηi ) inverse link function , φ scale parameter ) η linear predictor = Xβ xed eects + Zb random eects b conditional modes ∼ MVN(0, Σ(θ) variance- covariance matrix )
  • 13. Denitions Estimation Inference Challenges open questions References What are random eects? a way to account for among-individual, within-block correlation a compromise between complete pooling (σ2 among = 0) and xed eects (σ2 among → ∞) levels selected at random from a larger population a way do to shrinkage estimation/share information among levels a way to estimate variability among levels a way to allow predictions on unmeasured levels
  • 14. Denitions Estimation Inference Challenges open questions References What are random eects? a way to account for among-individual, within-block correlation a compromise between complete pooling (σ2 among = 0) and xed eects (σ2 among → ∞) levels selected at random from a larger population a way do to shrinkage estimation/share information among levels a way to estimate variability among levels a way to allow predictions on unmeasured levels
  • 15. Denitions Estimation Inference Challenges open questions References What are random eects? a way to account for among-individual, within-block correlation a compromise between complete pooling (σ2 among = 0) and xed eects (σ2 among → ∞) levels selected at random from a larger population a way do to shrinkage estimation/share information among levels a way to estimate variability among levels a way to allow predictions on unmeasured levels
  • 16. Denitions Estimation Inference Challenges open questions References What are random eects? a way to account for among-individual, within-block correlation a compromise between complete pooling (σ2 among = 0) and xed eects (σ2 among → ∞) levels selected at random from a larger population a way do to shrinkage estimation/share information among levels a way to estimate variability among levels a way to allow predictions on unmeasured levels
  • 17. Denitions Estimation Inference Challenges open questions References What are random eects? a way to account for among-individual, within-block correlation a compromise between complete pooling (σ2 among = 0) and xed eects (σ2 among → ∞) levels selected at random from a larger population a way do to shrinkage estimation/share information among levels a way to estimate variability among levels a way to allow predictions on unmeasured levels
  • 18. Denitions Estimation Inference Challenges open questions References What are random eects? a way to account for among-individual, within-block correlation a compromise between complete pooling (σ2 among = 0) and xed eects (σ2 among → ∞) levels selected at random from a larger population a way do to shrinkage estimation/share information among levels a way to estimate variability among levels a way to allow predictions on unmeasured levels
  • 19. Denitions Estimation Inference Challenges open questions References Outline 1 Examples and denitions 2 Estimation Overview Methods 3 Inference 4 Challenges open questions
  • 20. Denitions Estimation Inference Challenges open questions References Maximum likelihood estimation L(Yi |θ, β) likelihood = · · · L(Yi |β, b) data|random eects × L(b|Σ(θ)) random eects db Best t is a compromise between two components (consistency of data with xed eects and conditional modes; consistency of random eect with RE distribution)
  • 21. Denitions Estimation Inference Challenges open questions References Integrated (marginal) likelihood −10 −5 0 5 10 0.0 0.2 0.4 0.6 0.8 1.0 conditional mode value (u) Scaledprobability L(b|σ2 ) L(x|b, β) Lprod
  • 22. Denitions Estimation Inference Challenges open questions References Shrinkage: Arabidopsis conditional modes q q q q q q q q q q q q q q q q q q q q q q q q Genotype Mean(log)fruitset 0 5 10 15 20 25 −15 −3 0 3 q q q q q q q q q q q q q q q q q q q q q q q q 3 2 10 8 10 4 3 9 9 4 6 4 2 6 10 5 7 9 4 9 11 2 5 5
  • 23. Denitions Estimation Inference Challenges open questions References Estimation methods deterministic : various approximate integrals (Breslow, 2004) . . . stochastic (Monte Carlo): frequentist and Bayesian (Booth and Hobert, 1999; Ponciano et al., 2009; Sung, 2007)
  • 24. Denitions Estimation Inference Challenges open questions References Deterministic approaches PQL fast and biased, especially for binary/low-count data: (MASS:glmmPQL) Laplace intermediate (lme4:glmer, glmmML, glmmADMB, R2ADMB (AD Model Builder)) Gauss-Hermite quadrature slow but accurate (lme4:glmer, glmmML, repeated) INLA Bayesian, very exible: INLA General trade-o between exibility (ADMB/glmmADMB) and eciency (lme4)
  • 25. Denitions Estimation Inference Challenges open questions References Stochastic approaches Mostly Bayesians (Bayesian computation handles high-dimensional integration) various avours: Gibbs sampling, MCMC, MCEM, etc. generally slower but more exible simplies many inferential problems must specify priors, assess convergence/error specialized: glmmAK, MCMCglmm (Hadeld, 2010), bernor general: glmmBUGS, R2WinBUGS, BRugs (WinBUGS/OpenBUGS), R2jags, rjags (JAGS), glmer2stan, Stan
  • 26. Denitions Estimation Inference Challenges open questions References Estimation: example (McKeon et al., 2012) Log−odds of predation −6 −4 −2 0 2 Symbiont Crab vs. Shrimp Added symbiont q q q q q q q q q q q q q q q GLM (fixed) GLM (pooled) PQL Laplace AGQ
  • 27. Denitions Estimation Inference Challenges open questions References Outline 1 Examples and denitions 2 Estimation Overview Methods 3 Inference 4 Challenges open questions
  • 28. Denitions Estimation Inference Challenges open questions References Wald tests Wald tests (e.g. typical results of summary) based on information matrix assume quadratic log-likelihood surface exact for regular linear models; only asymptotically OK for GLM(M)s computationally cheap approximation is sometimes awful (Hauck-Donner eect)
  • 29. Denitions Estimation Inference Challenges open questions References 2D proles for coral predation Scatter Plot Matrix .sig01 2 4 6 8 101214 −3 −2 −1 0 (Intercept) 0 5 10 15 10 15 0 1 2 3 tttcrabs −10 −8 −6 −4 −2 0 −4 −2 0 0 1 2 3 tttshrimp −10 −8 −6 −4 −2 −6 −4 −2 0 1 2 3 tttboth −12 −10 −8 −6 −4 −2 0 1 2 3
  • 30. Denitions Estimation Inference Challenges open questions References Likelihood ratio tests better, but still have to deal with two nite-size problems: denominator degrees of freedom (when estimating scale) numerator is only asymptotically χ2 anyway (Bartlett corrections) Kenward-Roger correction? (Stroup, 2014) Prole condence intervals: moderately expensive/fragile
  • 31. Denitions Estimation Inference Challenges open questions References Parametric bootstrapping t null model to data simulate data from null model t null and working model, compute likelihood dierence repeat to estimate null distribution should be OK but ??? not well tested (assumes estimated parameters are suciently good)
  • 32. Denitions Estimation Inference Challenges open questions References Parametric bootstrap results True p value Inferredpvalue 0.02 0.04 0.06 0.08 0.02 0.06 Osm Cu H2S 0.02 0.06 0.02 0.04 0.06 0.08 Anoxia
  • 33. Denitions Estimation Inference Challenges open questions References Bayesian approaches If we have a good sample from the posterior distribution (Markov chains have converged etc. etc.) we get most of the inferences we want for free by summarizing the marginal posteriors post hoc Bayesian can work, but mode at zero causes problems
  • 34. Denitions Estimation Inference Challenges open questions References Outline 1 Examples and denitions 2 Estimation Overview Methods 3 Inference 4 Challenges open questions
  • 35. Denitions Estimation Inference Challenges open questions References On beyond R Julia: MixedModels package SAS: PROC MIXED, NLMIXED AS-REML Stata (GLLAMM, xtmelogit) AD Model Builder HLM, MLWiN
  • 36. Denitions Estimation Inference Challenges open questions References Challenges Small/medium data: inference, singular ts (blme, MCMCglmm) Big data: speed! Worst case: large n, small N (e.g. telemetry/genomics) Model diagnosis Condence intervals accounting for uncertainty in variances See also: http://rpubs.com/bbolker/glmmchapter, https: //groups.nceas.ucsb.edu/non-linear-modeling/projects
  • 37. Denitions Estimation Inference Challenges open questions References What about space? Sometimes blocks are spatial partitions (sites, zip codes, states) O-the-shelf methods for true spatial GLMMs? (Dormann et al., 2007) Correlation of residuals or conditional modes? INLA; GeoBUGS; ADMB lme4: hacking Z: pedigrees, moving average, CAR models? lme4: flexLambda branch methods also apply to temporal, phylogenetic correlations (Ives and Helmus, 2011)
  • 38. Denitions Estimation Inference Challenges open questions References Next steps Complex random eects: regularization, model selection, penalized methods (lasso/fence) Flexible correlation and variance structures Flexible/nonparametric random eects distributions hybrid improved MCMC methods Reliable assessment of out-of-sample performance
  • 39. Denitions Estimation Inference Challenges open questions References Banta, J.A., Stevens, M.H.H., and Pigliucci, M., 2010. Oikos, 119(2):359369. ISSN 1600-0706. doi:10.1111/j.1600-0706.2009.17726.x. Booth, J.G. and Hobert, J.P., 1999. Journal of the Royal Statistical Society. Series B, 61(1):265285. doi:10.1111/1467-9868.00176. Breslow, N.E., 2004. In D.Y. Lin and P.J. Heagerty, editors, Proceedings of the second Seattle symposium in biostatistics: Analysis of correlated data, pages 122. Springer. ISBN 0387208623. Dormann, C.F., McPherson, J.M., et al., 2007. Ecography, 30(5):609628. doi:10.1111/j.2007.0906-7590.05171.x. Hadeld, J.D., 2010. Journal of Statistical Software, 33(2):122. ISSN 1548-7660. Ives, A.R. and Helmus, M.R., 2011. Ecological Monographs, 81(3):511525. ISSN 0012-9615. doi:10.1890/10-1264.1. McKeon, C.S., Stier, A., et al., 2012. Oecologia, 169(4):10951103. ISSN 0029-8549. doi:10.1007/s00442-012-2275-2. Ponciano, J.M., Taper, M.L., et al., 2009. Ecology, 90(2):356362. ISSN 0012-9658. Stroup, W.W., 2014. Agronomy Journal, 106:117. doi:10.2134/agronj2013.0342. Sung, Y.J., 2007. The Annals of Statistics, 35(3):9901011. ISSN 0090-5364. doi:10.1214/009053606000001389.