This course is an intense introduction to regression methods in ecology from a frequentist and Bayesian perspective. Topics include ordinary regression, generalized linear models, linear and nonlinear mixed effects models, and generalized linear mixed effects models.

## Announcements

• January 5
• December 15
• As an extra hint on drawing the last graph in Problem 2, there is code at the end of lecture 29 that could easily be adapted for this purpose. The code contains a function plot.lattice2 that draws graphs for a single apple tree. Change it so that it draws graphs for a single Expt instead. After deleting some lines that are unnecessary (three lines in the beginning that remove apples with too few values and also the panel.abline for the OLS line and then adjusting the key accordingly) all that is left to do is modify func1 and func2. These need be written so as to yield a different parabola depending on the value of Expt. I would write out the whole regression equation here and then use the Expt argument of plot.lattice2 to select the coefficients that you need depending on the whether Expt=='II' or Expt=='III'.
• Notes for lecture 28 and lecture 29 are posted.
• There was a typo in the hint to Problem 1, Question 6, now fixed. The term labeled dispersion in the summary output of gamma regression is the scale parameter. You need to calculate the shape parameter from the estimated log mean and the scale.
• December 14: Notes for lecture 26 and lecture 27 are posted. The notes for the remaining lectures on multilevel models will be posted soon.
• December 8
• Final exam is posted and is due Friday, December 17.
• The R code used in lecture 29 is posted.
• December 6
• The R code used in lecture 28 is posted.
• Today's class will use the class will use the inverts data from before and the apples data set.
• The R code used in lecture 27 is posted.
• December 3: Notes for lecture 24 are posted.
• December 1: The R code used in lecture 26 is posted.
• November 28
• Monday's class will use the inverts data set as well as the birds data set from before.
• Notes for lecture 23 are posted.
• November 24
• Assignment 10 is posted and is due Friday, December 3.
• The R code used in lecture 25 is posted.
• November 21
• Apparently there's a bug in WinBUGS that caused us to get the wrong answer for the separate intercepts model. WinBUGS does work with all the other models we considered. A work-around is to download the open source version OpenBUGS from http://www.openbugs.info/w/ and install it. Also within R install the BRugs package from the CRAN site. The bugs function we've been using will run OpenBUGS instead of WinBUGS if you include the argument program='OpenBUGS'. OpenBUGS gets the right answer for the separate intercepts model and matches the results from JAGS.
• The R code used in lecture 24 is posted.
• Solutions to assignment 8 are posted.
• November 20: Notes for lecture 22 are posted.
• November 18: Notes for lecture 21 are posted.
• November 15
• The R code used in lecture 23 is posted.
• The due date for Assignment 9 has been changed to Tuesday, November 23.
• Today's class will use the birds data set.
• Notes for lecture 20 are posted.
• November 12
• The R code used in lecture 22 is posted.
• Assignment 9 is posted and is due Friday, November 19.
• November 11Solutions to assignment 7 are posted.
• November 10: Notes for lecture 19 are posted.
• November 9: The R code used in lecture 21 is posted.
• November 8: Notes for lecture 18 are posted.
• November 7
• November 4
• November 3: Notes for lecture 17 are posted.
• October 31: Data for Monday's class: parasites and last week's data.
• October 28
• The R code used in lecture 18 is posted.
• Assignment 7 is posted and is due Friday, November 5.
• October 26: The R code used in lecture 17 is posted.
• October 25Solutions to assignment 5 are posted.
• October 24: Data for Monday's class.
• October 22:
• October 18: The R code used in lecture 15 is posted.
• October 17:
• The data set needed for Monday's class is the Galapagos data set.
• The R code and BUGS programs used in lecture 14 are posted.
• October 14:
• An additional hint on constructing profile likelihood confidence intervals has been added to Assignment 5.
• Assignment 6 is posted and is due Tuesday, October 26.
• Notes for lecture 10 are posted.
• October 13: Solutions to assignment 4 are posted.
• October 12: The R code and BUGS programs used in lecture 13 are posted.
• October 10:
• Be sure to have either WinBUGS or JAGS loaded on your computer and to verify that everything works. Use the code from lecture 12 as a check.
• The data file needed for Monday's class is the ipomopsis data set taken from Michael Crawley's The R Book, Chapter 12, that he uses to illustrate analysis of covariance.
• October 7:
• Assignment 5 is posted and is due Friday, October 15.
• The R code used in lecture 12 is posted.
• October 6:
• October 5:
• October 3: Data sets needed for Monday's class are the aphids data set (used previously), the slugs data set, and the Galapagos data set.
• October 2: Notes for lecture 8 are posted.
• September 30:
• Assignment 4 is posted and is due Friday, October 8.
• The R code used in lecture 10 is posted.
• September 29: Solutions to assignment 2 are posted.
• September 28: Notes for lecture 6 and lecture 7 are posted.
• September 27:
• A second hint has been added to Assignment 3.
• The R code used in lecture 9 is posted.
• September 22:
• Assignment 3 is posted and is due Friday, October 1.
• The R code used in lecture 8 is posted.
• September 20: The R code used in lecture 7 is posted.
• September 19: For Monday's class we will need the slugs data set from Michael Crawley's web site for his textbook The R Book.
• September 18
• September 14
• September 13: The R code used in lecture 5 is posted.
• September 12: For Monday's class download the R code that fits the models from lecture 2. No new data or packages are needed. We'll be using the tadpoles.txt data from lecture 2 and the effects package.
• September 11: Notes for lecture 4 are posted.
• September 8: The R code used in lecture 4 is posted.
• September 7: Notes for lecture 3 are posted.
• September 4: Notes for lecture 2 are posted.
• September 2
• The R code used in lecture 3 is posted.
• Assignment 1 is posted and is due Friday, September 10.
• August 31: Notes for lecture 1 are posted.
• August 30: The R code used in lecture 2 is posted.
• August 29: Here are the files needed for lecture 2 (August 30).
• dataset
• description of data (if interested)
• If you can figure out how to do it, download and install the effects package into the version of R on your laptop. [Use Packages menu in Windows; Packages & Data menu in Mac OS X]
• August 25: The R code used in lecture 1 is posted.
• August 24: Course description is posted.