Allison Horst - Course & Workshop Materials

Bren School of Environmental Science and Management (UC Santa Barbara)


ESM 206: Introduction to environmental data analysis & stats in R

esm_206

ESM 206 MATERIALS (FALL 2019)


Course description: Develop critical thinking, technical and communication skills to successfully approach and answer environmental questions using quantitative and qualitative data. Topics include: data wrangling using the tidyverse and tidy data principles, exploratory data analysis and visualization, descriptive statistics, uncertainty, hypothesis testing, data visualization and communication. Best practices for reproducibility, version control and collaboration are emphasized throughout. Skills will be developed through wrangling, analysis and communication of datasets using R, RStudio and GitHub.

Course goals:


ESM 206 course syllabus (Fall 2019)

ESM 206 Code of Conduct


WEEK LECTURES LAB MATERIALS READING
0 During orientation: get started with R, RStudio and GitHub Get R/RStudio and the tidyverse
Get started with Git/GitHub
None
1 Lecture 1: Course intro; computational reproducibility; R & RStudio

Lecture 2: Naming things; tidy data; basic troubleshooting and getting help with R
Lab 1: Meet RStudio, projects, scripts, basic reading & wrangling, intro to ggplot2Broman & Woo "Data organization in spreadsheets

Lowndes et al. "Our path to better science in less time using open data science tools"
2 Lecture 3: Code style tips; intro to R Markdown

Lecture 4: Version control with Git & GitHub overview; exploratory data visualization
Lab 2: Intro to R Markdown, data wrangling continued, tidyr::pivot_*, joins, and customizing a ggplot graphWilson et al. "Good enough practices in scientific computing"

Chapters 4 - 7 in "Fundamentals of Data Visualization" by Claus O. Wilke
3 Lecture 5: Data visualization Part 1
Lecture 6: Data visualization Part 2
Lab 3: Data visualization, dplyr::case_when(), purrr::modify_if(), writing files & saving figures, {here} for file pathsChapters 9 - 11 in "Fundamentals of Data Visualization" by Claus O. Wilke

Ch. 5 (Data Transformation) in R for Data Science by Grolemund & Wickham
4 Lecture 7: Axis labels & figure captions; types of data; central tendency & data spread

Lecture 8: Guest lecture (Jessica Couture) - Open Science and Metadata
Lab 4: Meet GitHub; work between RStudio & GitHub; tabs in markdown; interactive graphs & tables with plotly & DT; annotate ggplotsNo new reading - catch up on previous weeks & study for midterm
5 Lecture 9: Exploring distributions, probability density, uncertainty intro, and hypothesis test overview

Midterm Wednesday
Lab 5: Counting things, exploring normality, parsing dates, t-tests introNo Week 5 reading
6 Lecture 10: What are p-values; what aren't p-values; one- and two-sample t-tests

Lecture 11: Means comparisons continued (t-tests)
Lab 6: two-sample t-tests, intro to basic functions and for loopsUsing effect size - or why the p-value is not enough
7 (Monday holiday)
Lecture 12: Type II and Type II errors, effect size, one-way ANOVA intro
Lab 7: T-tests, in-line reporting of hypothesis test outcomes, effect size, a table with kableExtra
8 Lecture 13: One-way ANOVA continued, post-hoc tests, overview of rank-based tests
Lecture 14: Chi-square test for independence
Lab 8: One-way ANOVA, chi-square, tables, plotting means and standard errors
9 Lecture 15: Simple linear regression by OLS, coefficient of determination, Pearson's r
Lecture 16 handout: Multiple linear regression introduction (read through before taking quiz)
Lab 9: Simple linear regression (see docs on GauchoSpace)
10 Lecture 17: Multiple linear regression continued
Lecture 18: Moving forward with regression, recap, and more important things
Lab 10: Multiple linear regression & other fun stuff

Course resources:

ESM 206 ARCHIVES


ESM 244: Advanced methods for environmental data analysis in R

esm_206

Materials in development, excuse the dust


ESM 244 course description: A survey course in advanced topics in statistics and data analysis for environmental scientists (ordinal and multinomial logistic regression, bootstrapping, non-linear models, intro to time-series analysis, spatial data analysis and interpolation, ordination methods, cluster analysis, text mining, etc.) while continuing to build skills and habits in data science (data wrangling, analysis & computational reproducibility in R/RStudio, version control and collaboration with R and GitHub). Term project: build a Shiny app.


ESM 244 course syllabus (Winter 2019)

ESM 244 Code of Conduct


WEEK LECTURES LAB MATERIALS
1 Lecture 1: Course intro + 206 review
Lecture 2: Binary + ordinal logistic regression
Lab 1: data wrangling + visualization review
2 Lecture 3: Logistic regression, PCA intro
Lecture 4: PCA/RDA continued
Lab 2: Ordinal logistic regression, PCA, Shiny example
3 Lecture 5: Bootstrapping
Lecture 6: Exploring missingness
Lab 3: Bootstrap, assessing missingness
4 Lecture 7: Nonlinear least squares
Lecture 8: Longitudinal data
Lab 4: NLS, panel regression example
5 Lecture 9: Exploring time series data
Lecture 10: Autocorrelation, MA, ARIMA intro
Lab 5: Intro to time series analysis
6 Lecture 11: Spatial data, projections, variograms
Lecture 12: Kriging
Lab 6: Getting, wrangling and viewing spatial data
7 Lecture 13: Point pattern analysis, k-means clustering Lab 7: Rasters, Kriging, PPA
8 Lecture 14: Hierarchical clustering, Bayesian thinking intro
Lecture 15: Bayesian + text analysis case studies
Lab 8: Cluster analysis (k-means + hierarchical), + some text wrangling/sentiment analysis
9 Lecture 16: Graph theory terms, data sci collaboration Lab 9: Network analysis + cool extras


Workshops


About Allison

Allison is a lecturer at the Bren School of Environmental Science and Management (UC Santa Barbara), where she has been teaching data analysis, statistics, and presentation skills courses in an applied environmental graduate program since 2012. In addition, she teaches introductory and refresher workshops in R for incoming graduate students and alumni. She is a co-founder of R-Ladies Santa Barbara, and recently co-founded a #tidytuesday coding club at UCSB. Allison completed her studies in engineering (BS Chemical Engineering, MS Mechanical Engineering) before earning her PhD in Environmental Nanotoxicology from UCSB.

Teaching

  • ESM 206: Introductory data analysis and statistics in environmental science and management (2012 - present)
  • ESM 244: Advanced methods in environmental data science (2012 - present)
  • ESM 438: Presentation skills for environmental professionals (2013 - present)
  • Calculus intensive workshop: a 2-week calculus refresher course for incoming graduate students at the Bren School (2008 - present)
  • Data analysis workshop: a 2-week quantitative methods and introduction to R workshop for incoming PhD students at UCSB (2016 - present)

Distinctions

  • Bren School Distinguished Teaching Award (2018)
  • UC Santa Barbara Distinguished Teaching Award (2019)

Allison is also a fine artist, graphic designer, fly-fisher, hiker, backpacker, wanderer, and proud aunt to three nieces and two nephews. She splits time between Santa Barbara, CA, and Aspendell, CA, where she lives with her partner Greg and their silly rescue dog, Teddy.


We're proud Openscapes Champions

Openscapes
--> -->