While the topics covered are broad, each week will feature different examples from genetics, ecology, molecular, and evolutionary biology highlighting uses of each individual set of techniques.

F = Fieberg, R4DS = Wickham et al., U/P for linked pdfs = biol607

Change .html to .Rmd in your browser to get the markdown of all lectures, etc.

Recorded Lecture: All lectures and labs will be recorded and are available at https://www.youtube.com/playlist?list=PLZRMqMK8aRmIMuiEX-QVxLNk2o6SlRa-m

Turning in Homework: All homework should be completed using RMarkdown or Quarto. You’ll freely mix answers in text and code there. Use projects. Please zip up the full project folder for each to submit so that we have the .rmd (or .qmd), .html output, data, etc. and can recompile your homework if we need to. An ideal project structure would be something like this:

homework_X/
  |— markdown
  |— scripts
  |— data

directory structure, so that all data is in data/. Please zip up the archive for the homework and standardize filenames as follows: number_lastName_firstName_2023.zip where number is the week number the homework is due (from weeks below) and make sure to include the 0s for numbers like 01), and your last and first names - well, you should know them!

To submit homework, use the dropbox link you were sent by the TA.

Block 1: Introduction to Programming and Reproducibility

Week 1.

9/4/2023
Lecture: Class intro, Intro to R.
Lab: Matrices, Lists and Data Frames. Introduction to Markdown
Reading: R4DS Intro, Workflow basics, Scripts and Projects, Code Style, Vectors, and Quarto
Further Exploration: Quarto Formats, https://quarto.org/ for everything!
Cheat Sheets: Quarto Cheat Sheet
Install R: Go to https://cloud.r-project.org/ and get the right version of R for you. Then, go to https://www.rstudio.com/products/rstudio/download/#download and install Rstudio.
Etherpad: https://etherpad.wikimedia.org/p/607-intro-2023
Homework: Intro to R and Data Frames

Week 2.

9/11/2023
Lecture: Data visualization
Lab Topic: Introduction to ggplot2.
Reading: R4DS Chapters on Data Vizualization, Layers of Plots, and Graphics for Communication, Introducing Palmer Penguins
Further Exploration: Friendly 2008 on History of Data Viz, Unwin 2008, DC Starting with Data, Fundamentals of Data Visualization - note, this is a whole book, but scan it - it’s amazing
Etherpad: https://etherpad.wikimedia.org/p/dataviz-2023
Packages used this Week: ggplot2, ggridges, ggdist - install.packages(c("ggplot2", "ggridges", "palmerpenguins", "ggdist"))
Cheat Sheets: Ggplot2 cheat sheet, Choosing a good chart cheat sheet
Homework: ggplot2 homework

Week 3.

9/18/2023
Lecture/Lab: Data import, using libraries, Pipes, data manipulation, summarization, and making it tidy
Data: Portal Data - and learn more here
Reading: Data organization in spreadsheets, R4DS Chapters on data import, pipes, data transformation, tidy data
Optional Reading: 10 Commandments for Good Data Managament, Managing Data Frames with the Dplyr package, Strings, factors, and Dates
Cheat Sheets: Reading data into R, Dplyr cheat sheet.
Packages: install.packages(c("dplyr", "janitor", "skimr", "lubridate", "tidyr", "readr", "readxl", "tibble")) - readr, readxl, tibble, skimr, janitor, visdat
Etherpad: http://etherpad.wikimedia.org/p/607-tidy-2023
Homework: Data Manipulation and Pivot homework

Week 4.

9/25/2023
Lecture: What is a Sample? and Sampling Distribution.
Lab Topic: Sampling and simulation.
Reading: Cumming et al. 2007 on SDs, SEs, and CIs
Etherpad: https://etherpad.wikimedia.org/p/sampling-2023
Packages for the Week: dplyr - install.packages(c("dplyr", "purrr"))
Homework: Sampling, Simulation, and Tidy Tuesday

Block 2: Linear Models for Data Analysis

Week 9

10/30/2023
Lecture: Random Effects, Mixed Models
Data: TBA
Lab Topic: Mixed Models
Packages for the Week: install.packages(c("glmmTMB", "lme4", "merTools", "broom.mixed))
Reading: Linear Mixed Effects Models, Generalized Linear Mixed Effects Models
Additional Reading: Generalized linear mixed models: a practical guide for ecology and evolution, Gelman and Hill Ch 12 login/pass biol609, Zuur ch. 9. Your One Stop FAQ: Your One Stop FAQ: Ben Bolker’s Mixed Model’s FAQ, optimizer tips
Etherpad: https://etherpad.wikimedia.org/p/607-mixed-2023

MIDTERM: Due Tues Nov 17th, 5pm. Get it here

Block 3. Experimental and Observational Study Design and Causal Inference

Week 12.

11/20/2023
Thanksgiving Week. Paper Discussion: Discussion of papers - see here for assignments
Optional Reading: Collider Bias and Covid
Etherpad: https://etherpad.wikimedia.org/p/607-obs-2023

Block 4. Drawing Inference from Studies

Week 13.

11/27/2023
Lecture: Ways of Knowing: NHT, NHT and testing models, Power Analysis
Lab Topic: Null Hypothesis Testing, Power Analysis
Data for Lab: mole rats, intertidal algae, cryptosporidium infection, Keeley et al. data
Reading: W&S 20, Muff et al. 2022 on p-values, Feiberg on Maximum Likelihood
Etherpad: https://etherpad.wikimedia.org/p/607-nht-eval-2023
Packages for The Week: install.packages(c("car", "MASS", "profileModel"))

Week 14

12/4/2023

Lecture: Ways of Knowing: Cross-Validation and AIC
Lab Topic: Cross-Validation and AIC
Reading: AIC in Behavioral Ecology, Fieberg on Modeling Strategies, Aho et al. 2014 on BIC
Optional Reading: Ellison 1996
Optional Books: Model Selection and Multimodel Inference Packages for The Week: install.packages(c("AICcmodavg")
Etherpad: https://etherpad.wikimedia.org/p/607-cv-2023

Week 15

12/11/2023
Project work and Project Presentations on Dec 15th