Module 8: Bayesian Statistics for Genetics
Instructors: Jon Wakefield and Ken Rice
This page, updated throughout the course, will feature slides from our sessions, and examples for you to try.
Prior to the module, please install up-to-date versions of R and RStudio on the laptop you will use during the
summer institute. Both are free.
Other software that will be useful, but only used in parts of the module:
- Stan: Windows users first need the Rtools toolchain, Mac users may need the toolchain and corresponding tools. Then install R's rstan package.
- JAGS: Download and install JAGS itself , then install R's rjags package
- INLA: To get the INLA package for R, follow the non-standard procedure here
- WinBUGS: you will need WinBUGS and the R2WinBUGS R package. If you don't remember where to point and click, watch the (unrated) WinBUGS the Movie (may require the Ruffle Extension to view. Note making WinBUGS work on a Mac requires a Windows emulator such as HomeBrew, and you may prefer just to use JAGS instead.
Slides and exercises
Script files are posted following each session; these will contain our R code for the exercises. To make them work on your computer, remember to modify file names and locations appropriately. Also note that many different 'correct' solutions are possible. All times/dates are Pacfic, i.e. Seattle time.
The module has 10 sessions, each of 80 minutes. The standard format for a session is approximately:
- 50 minutes of pre-recorded lecture material
- 20 minutes of code demonstrations and exercises for you to try, with small-group "breakout" Zoom sessions available, attended by other class participants, and Teaching Assistants. Please help each other out!
- 10 minute discussion of exercises, where the instructors will present possible solutions and answer questions
Please join the module's Slack channel, where you can ask questions and see real-time updates from the instructors and TAs.
Zoom Room for all sessions
Slides and code used in-class
Wednesday, July 14th |
Time |
Topic |
Lecture |
Exercises/Discussion |
11:30am-12:50pm |
0/1. Introductions, motivation for Bayes |
Slides0 [.pdf] Slides [.pdf], ZoomRec |
Exercises, Key [.pdf], ZoomRec |
1:10pm-2:30pm |
2. Binomial sampling, part 1 |
Slides [.pdf], ZoomRec |
Demo and exercises [.Rmd, .pdf], Key [.R], ZoomRec |
Thursday, July 15th |
Time |
Topic |
Lecture |
Exercises/Discussion |
8:00am-9:20am |
3. Binomial sampling, part 2 |
Slides [.pdf], ZoomRec |
Demo and exercises [.Rmd, .pdf], Key [.R], ZoomRec |
9:40am-11:00am |
4. Linear models |
Slides [.pdf], ZoomRec |
Exercises Script from demo[.R], Key [.pdf], ZoomRec |
11:30am-12:50pm |
5. Multinomial Samples |
Slides [.pdf], ZoomRec |
Demo and exercises [.Rmd, .pdf], Key [.R], ZoomRec |
1:10pm-2:30pm |
6. Model selection and averaging |
Slides [.pdf], Code [.R], ZoomRec |
Exercises, Key [.pdf], ZoomRec |
Friday, July 16th |
Time |
Topic |
Lecture |
Exercises/Discussion |
8:00am-9:20am |
7. Generalized Linear Models |
Slides [.pdf], prostmat.csv, prostz.txt, ZoomRec |
Demo and exercises [.Rmd, .pdf], Key [.R], ZoomRec |
9:40am-11:00am |
8. Meta-analysis |
Slides [.pdf], ZoomRec |
Exercises Script file [.R], Key [.pdf], ZoomRec |
11:30am-12:50pm |
9. Testing and Multiple Testing |
Slides [.pdf], prostmat.csv, prostz.txt, ZoomRec |
Demo [.Rmd, .pdf] (no exercises for this session), ZoomRec |
1:10pm-2:30pm |
10. Software examples |
Slides [.pdf], |
See demo resources below, ZoomRec |
Resources for Session 10: most of the examples run the HWE example - each example is self-contained
Comments forms and attendance certificates are available here - requires SISG account.
Datasets
- ASAgene.txt: Data for Session 2 and 3
- diagen_bma: Data and posterior simulations for Session 6 - load into an R session with load()
- yX_FTO: Copy of the FTO data, for Session 6 - load into an R session with load()
Other resources
|