STAT 408
Statistical Computing and Graphical Analysis

This Course:

  • Is a programming course rather than a Statistical theory course
  • Cannot teach you everything there is to know about R
  • Can teach you how to teach yourself
  • Will make you an expert in R

Warning: Programming is Frustrating

  • All statistical analysis requires the use of the computer
  • Computers do exactly what we tell them to do, not what we’re thinking they should do
  • Lots of finicky little conventions must be memorized
  • Fun part is to get it to do new and beautiful things. There is a reward in the end. Computers are fast and accurate.

Computing Basics

  • Stay organized. Create a folder for STAT 408, subfolders as needed for notes, homework, …
  • We will work with .qmd, .Rmd, .R files
  • Data files: .csv, .txt
  • Know where files reside
  • Back up your work: onedrive (Free for MSU Students), Google Drive, Dropbox

Programming in General

  • Plan ahead “Top-Down” programming
  • Programming is an iterative process
  • Reproducibility - code should make sense a year from now
  • Avoid programming with graphical interfaces - or save code run in background

R is:

  • A programming environment
  • A way to run stat analyses
  • Built of functions and objects
  • Great at making complex plots (not necessarily easy)
  • A project involving work from hundreds of people
  • Rapidly expanding.

R is not:

  • A spreadsheet.
  • A database.
  • A place to enter data from the field directly.
  • A point-and-click environment.
  • A commercial product with professional support staff.