Introduction to WinBUGS for Ecologists introduces applied Bayesian modeling to ecologists using the highly acclaimed, free WinBUGS software. It offers an understanding of statistical models as abstract representations of the various processes that give rise to a data set. Such an understanding is basic to the development of inference models tailored to specific sampling and ecological scenarios. The book begins by presenting the advantages of a Bayesian approach to statistics and introducing the WinBUGS software. It reviews the four most common statistical distributions: the normal, the uniform, the binomial, and the Poisson. It describes the two different kinds of analysis of variance (ANOVA): one-way and two- or multiway. It looks at the general linear model, or ANCOVA, in R and WinBUGS. It introduces generalized linear model (GLM), i.e., the extension of the normal linear model to allow error distributions other than the normal. The GLM is then extended contain additional sources of random variation to become a generalized linear mixed model (GLMM) for a Poisson example and for a binomial example. The final two chapters showcase two fairly novel and nonstandard versions of a GLMM. The first is the site-occupancy model for species distributions; the second is the binomial (or N-) mixture model for estimation and modeling of abundance.
1. Chapter 1. Introduction 2. 1.1. Advantages of the Bayesian Approach to Statistics 3. 1.2. So Why Then Isn't Everyone a Bayesian? 4. 1.3. WinBUGS 5. 1.4. Why This Book? 6. 1.5. What This Book is not About: Theory of Bayesian Statistics and Computation 7. 1.6. Further Reading 8. 1.7. Summary 9. Chapter 2. Introduction to the Bayesian Analysis of a Statistical Model 10. 2.1. Probability Theory and Statistics 11. 2.2. Two Views of Statistics: Classical and Bayesian 12. 2.3. The Importance of Modern Algorithms and Computers for Bayesian Statistics 13. 2.4. Markov Chain Monte Carlo (MCMC) and Gibbs Sampling 14. 2.5. What Comes After MCMC? 15. 2.6. Some Shared Challenges in the Bayesian and the Classical Analysis of a Statistical Model 16. 2.7. Pointer to Special Topics in This Book 17. 2.8. Summary 18. Chapter 3. WinBUGS 19. 3.1. What is WinBUGS? 20. 3.2. Running WinBUGS from R 21. 3.3. WinBUGS Frees the Modeler in You 22. 3.4. Some Technicalities and Conventions 23. Chapter 4. A First Session in WinBUGS 24. 4.1. Introduction 25. 4.2. Setting Up the Analysis 26. 4.3. Starting the MCMC Blackbox 27. 4.4. Summarizing the Results 28. 4.5. Summary 29. Chapter 5. Running WinBUGS from R via R2WinBUGS 30. 5.1. Introduction 31. 5.2. Data Generation 32. 5.3. Analysis Using R 33. 5.4. Analysis Using WinBUGS 34. 5.5. Summary 35. Chapter 6. Key Components of (Generalized) Linear Models 36. 6.1. Introduction 37. 6.2. Stochastic Part of Linear Models: Statistical Distributions 38. 6.3. Deterministic Part of Linear Models: Linear Predictor and Design Matrices 39. 6.4. Summary 40. Chapter 7. t-Test 41. 7.1. t-Test with Equal Variances 42. 7.2. t-Test with Unequal Variances 43. 7.3. Summary and a Comment on the Modeling of Variances 44. Chapter 8. Normal Linear Regression 45. 8.1. Introduction 46. 8.2. Data Generation 47. 8.3. Analysis Using R 48. 8.4. Analysis Using WinBUGS 49. 8.5. Summary 50. Chapter 9. Normal One-Way ANOVA 51. 9.1. Introduction: Fixed and Random Effects 52. 9.2. Fixed-Effects ANOVA 53. 9.3. Random-Effects ANOVA 54. 9.4. Summary 55. Chapter 10. Normal Two-Way ANOVA 56. 10.1. Introduction: Main and Interaction Effects 57. 10.2. Data Generation 58. 10.3. Aside: Using Simulation to Assess Bias and Precision of an Estimator 59. 10.4. Analysis Using R 60. 10.5. Analysis Using WinBUGS 61. 10.6. Summary 62. Chapter 11. General Linear Model (ANCOVA) 63. 11.1. Introduction 64. 11.2. Data Generation 65. 11.3. Analysis Using R 66. 11.4. Analysis Using WinBUGS (And A Cautionary Tale About the Importance of Covariate Standardization) 67. 11.5. Summary 68. Chapter 12. Linear Mixed-Effects Model 69. 12.1. Introduction 70. 12.2. Data Generation 71. 12.3. Analysis Under a Random-Intercepts Model 72. 12.4. Analysis Under a Random-Coefficients Model Without Correlation Between Intercept and Slope 73. 12.5. The Random-Coefficients Model with Correlation between Intercept and Slope 74. 12.6. Summary 75. Chapter 13. Introduction to the Generalized Linear Model 76. 13.1. Introduction 77. 13.2. An Important but Often Forgotten Issue with Count Data 78. 13.3. Data Generation 79. 13.4. Analysis Using R 80. 13.5. Analysis Using WinBUGS 81. 13.6. Summary 82. Chapter 14. Overdispersion, Zero-Inflation, and Offsets in the GLM 83. 14.1. Overdispersion 84. 14.2. Zero-Inflation 85. 14.3. Offsets 86. 14.4. Summary 87. Chapter 15. Poisson ANCOVA 88. 15.1. Introduction 89. 15.2. Data Generation 90. 15.3. Analysis Using R 91. 15.4. Analysis Using WinBUGS 92. 15.5. Summary 93. Chapter 16. Poisson Mixed-Effects Model (Poisson GLMM) 94. 16.1. Introduction 95. 16.2. Data Generation 96. 16.3. Analysis Under a Random-Coefficients Model 97. 16.4. Summary 98. Chapter 17. Binomial “t-Test” 99. 17.1. Introduction 100. 17.2. Data Generation 101. 17.3. Analysis Using R 102. 17.4. Analysis Using WinBUGS 103. 17.5. Summary 104. Chapter 18. Binomial Analysis of Covariance 105. 18.1. Introduction 106. 18.2. Data Generation 107. 18.3. Analysis Using R 108. 18.4. Analysis Using WinBUGS 109. 18.5. Summary 110. Chapter 19. Binomial Mixed-Effects Model (Binomial GLMM) 111. 19.1. Introduction 112. 19.2. Data Generation 113. 19.3. Analysis Under a Random-Coefficients Model 114. 19.4. Summary 115. Chapter 20. Nonstandard GLMMs 1 116. 20.1. Introduction 117. 20.2. Data Generation 118. 20.3. Analysis Using WinBUGS 119. 20.4. Summary 120. Chapter 21. Nonstandard GLMMs 2 121. 21.1. Introduction 122. 21.2. Data Generation 123. 21.3. Analysis Using WinBUGS 124. 21.4. Summary 125. Chapter 22. Conclusions 126. APPENDIX. A List of WinBUGS Tricks 127. References 128. Index
Introduction to WinBUGS for Ecologists introduces applied Bayesian modeling to ecologists using the highly acclaimed, free WinBUGS software. It offers an understanding of statistical models as abstract representations of the various processes that give rise to a data set. Such an understanding is basic to the development of inference models tailored to specific sampling and ecological scenarios. The book begins by presenting the advantages of a Bayesian approach to statistics and introducing the WinBUGS software. It reviews the four most common statistical distributions: the normal, the uniform, the binomial, and the Poisson. It describes the two different kinds of analysis of variance (ANOVA): one-way and two- or multiway. It looks at the general linear model, or ANCOVA, in R and WinBUGS. It introduces generalized linear model (GLM), i.e., the extension of the normal linear model to allow error distributions other than the normal. The GLM is then extended contain additional sources of random variation to become a generalized linear mixed model (GLMM) for a Poisson example and for a binomial example. The final two chapters showcase two fairly novel and nonstandard versions of a GLMM. The first is the site-occupancy model for species distributions; the second is the binomial (or N-) mixture model for estimation and modeling of abundance.
1. Chapter 1. Introduction 2. 1.1. Advantages of the Bayesian Approach to Statistics 3. 1.2. So Why Then Isn't Everyone a Bayesian? 4. 1.3. WinBUGS 5. 1.4. Why This Book? 6. 1.5. What This Book is not About: Theory of Bayesian Statistics and Computation 7. 1.6. Further Reading 8. 1.7. Summary 9. Chapter 2. Introduction to the Bayesian Analysis of a Statistical Model 10. 2.1. Probability Theory and Statistics 11. 2.2. Two Views of Statistics: Classical and Bayesian 12. 2.3. The Importance of Modern Algorithms and Computers for Bayesian Statistics 13. 2.4. Markov Chain Monte Carlo (MCMC) and Gibbs Sampling 14. 2.5. What Comes After MCMC? 15. 2.6. Some Shared Challenges in the Bayesian and the Classical Analysis of a Statistical Model 16. 2.7. Pointer to Special Topics in This Book 17. 2.8. Summary 18. Chapter 3. WinBUGS 19. 3.1. What is WinBUGS? 20. 3.2. Running WinBUGS from R 21. 3.3. WinBUGS Frees the Modeler in You 22. 3.4. Some Technicalities and Conventions 23. Chapter 4. A First Session in WinBUGS 24. 4.1. Introduction 25. 4.2. Setting Up the Analysis 26. 4.3. Starting the MCMC Blackbox 27. 4.4. Summarizing the Results 28. 4.5. Summary 29. Chapter 5. Running WinBUGS from R via R2WinBUGS 30. 5.1. Introduction 31. 5.2. Data Generation 32. 5.3. Analysis Using R 33. 5.4. Analysis Using WinBUGS 34. 5.5. Summary 35. Chapter 6. Key Components of (Generalized) Linear Models 36. 6.1. Introduction 37. 6.2. Stochastic Part of Linear Models: Statistical Distributions 38. 6.3. Deterministic Part of Linear Models: Linear Predictor and Design Matrices 39. 6.4. Summary 40. Chapter 7. t-Test 41. 7.1. t-Test with Equal Variances 42. 7.2. t-Test with Unequal Variances 43. 7.3. Summary and a Comment on the Modeling of Variances 44. Chapter 8. Normal Linear Regression 45. 8.1. Introduction 46. 8.2. Data Generation 47. 8.3. Analysis Using R 48. 8.4. Analysis Using WinBUGS 49. 8.5. Summary 50. Chapter 9. Normal One-Way ANOVA 51. 9.1. Introduction: Fixed and Random Effects 52. 9.2. Fixed-Effects ANOVA 53. 9.3. Random-Effects ANOVA 54. 9.4. Summary 55. Chapter 10. Normal Two-Way ANOVA 56. 10.1. Introduction: Main and Interaction Effects 57. 10.2. Data Generation 58. 10.3. Aside: Using Simulation to Assess Bias and Precision of an Estimator 59. 10.4. Analysis Using R 60. 10.5. Analysis Using WinBUGS 61. 10.6. Summary 62. Chapter 11. General Linear Model (ANCOVA) 63. 11.1. Introduction 64. 11.2. Data Generation 65. 11.3. Analysis Using R 66. 11.4. Analysis Using WinBUGS (And A Cautionary Tale About the Importance of Covariate Standardization) 67. 11.5. Summary 68. Chapter 12. Linear Mixed-Effects Model 69. 12.1. Introduction 70. 12.2. Data Generation 71. 12.3. Analysis Under a Random-Intercepts Model 72. 12.4. Analysis Under a Random-Coefficients Model Without Correlation Between Intercept and Slope 73. 12.5. The Random-Coefficients Model with Correlation between Intercept and Slope 74. 12.6. Summary 75. Chapter 13. Introduction to the Generalized Linear Model 76. 13.1. Introduction 77. 13.2. An Important but Often Forgotten Issue with Count Data 78. 13.3. Data Generation 79. 13.4. Analysis Using R 80. 13.5. Analysis Using WinBUGS 81. 13.6. Summary 82. Chapter 14. Overdispersion, Zero-Inflation, and Offsets in the GLM 83. 14.1. Overdispersion 84. 14.2. Zero-Inflation 85. 14.3. Offsets 86. 14.4. Summary 87. Chapter 15. Poisson ANCOVA 88. 15.1. Introduction 89. 15.2. Data Generation 90. 15.3. Analysis Using R 91. 15.4. Analysis Using WinBUGS 92. 15.5. Summary 93. Chapter 16. Poisson Mixed-Effects Model (Poisson GLMM) 94. 16.1. Introduction 95. 16.2. Data Generation 96. 16.3. Analysis Under a Random-Coefficients Model 97. 16.4. Summary 98. Chapter 17. Binomial “t-Test” 99. 17.1. Introduction 100. 17.2. Data Generation 101. 17.3. Analysis Using R 102. 17.4. Analysis Using WinBUGS 103. 17.5. Summary 104. Chapter 18. Binomial Analysis of Covariance 105. 18.1. Introduction 106. 18.2. Data Generation 107. 18.3. Analysis Using R 108. 18.4. Analysis Using WinBUGS 109. 18.5. Summary 110. Chapter 19. Binomial Mixed-Effects Model (Binomial GLMM) 111. 19.1. Introduction 112. 19.2. Data Generation 113. 19.3. Analysis Under a Random-Coefficients Model 114. 19.4. Summary 115. Chapter 20. Nonstandard GLMMs 1 116. 20.1. Introduction 117. 20.2. Data Generation 118. 20.3. Analysis Using WinBUGS 119. 20.4. Summary 120. Chapter 21. Nonstandard GLMMs 2 121. 21.1. Introduction 122. 21.2. Data Generation 123. 21.3. Analysis Using WinBUGS 124. 21.4. Summary 125. Chapter 22. Conclusions 126. APPENDIX. A List of WinBUGS Tricks 127. References 128. Index