Stat 406 - Example R programs
R programs that have been discussed in lab (or in class) are included here.
Introduction to R
Introduction to the sp package.
R code for the Introduction to the sp package.
How to draw random samples
Illustration of using simulation to evaluate properties of estimators.
R code and comments for inv. dist. weighting and trend surfaces.
R code and comments for ordinary kriging 'by hand'.
R code and comments for semivariogram estimation and kriging.
Notes on read various data formats into R and working with matrices.