Miscellaneous (mostly) R Code
This is a place for miscellaneous R and other code I've put together for clients, co-workers or myself for learning and demonstration purposes. The attempt is made to put together some well-commented and/or conceptually clear code from scratch, though most functionality is readily available in any number of well-developed R packages. Typically examples are provided using such packages for comparison of results.
Model Fitting
Code related to fitting of various models.
standard regression, penalized regression, one factor random effects (R) (Julia) (Matlab), two factor random effects (R) (Julia) (Matlab), cubic spline, hurdle poisson, hurdle negbin, zero-inflated poisson, zero-inflated negbin, Cox survival, confirmatory factor analysis, EM mixture univariate, EM mixture multivariate, EM probit, EM pca, EM probabilistic pca, Gaussian Process noisy, Gaussian Process noise-free...
Bayesian (mostly with Stan/rstan)
BEST t-test, linear regression (Compare with BUGS version, JAGS), mixed model, mixed model with correlated random effects, beta regression, mixture model ...
SC and TR
Code specific to short courses and technical reports I put together from time to time.
Introduction to R, Generalized Additive Models, Machine Learning, ...
Other
Random shenanigans.
ggplot2 theme, FizzBuzz test (R) (julia), Scrape xkcd (R) (Python), Shakespearean Insulter, ...
Future
It may also include data sets, viz and other stuff at some point.