You really don’t want to miss Chi Feng‘s absolutely wonderful interactive demos.

(1) Markov chain Monte Carlo sampling

I believe this is exactly what Andrew was asking for a few Stan meetings ago:

Chi Feng’s Interactive MCMC Sampling Visualizer

This tool lets you explore a range of sampling algorithms including random-walk Metropolis, Hamiltonian Monte Carlo, and NUTS operating over a range of two-dimensional distributions (standard normal, banana, donut, multimodal, and one squiggly one). You can control both the settings of the algorithms and the settings of the visualizations. As you run it, it even collects the draws into a sample which it summarizes as marginal histograms.

Source code

The demo is implemented in Javascript with the source code on Chi Feng’s GitHub organization:

Wish list

3D (glasses or virtual reality headset) multiple chains in parallel scatterplot breadcrumbs Gibbs sampler Ensemble samplers User-pluggable densities (Andrew really wants this for Stan where you’d choose two dimensions of N to visualize)

(2) Gaussian Process visualization

This one’s also really elegant.

Chi Feng’s Gaussian process demo

It lets you lay down a few points and fit a 1D GP. It lets you choose kernel and hperparameters, and even sample regression functions from it conditioned on the data you provide.

Wish list

3D (OK, I’m obssesed, but this one would be great on a 2D grid with a 3D visualization of a GP being fit) Estimating hyperparameters (didn’t seem like it was doing this—may be a bit challenging for Javascript!)

Source code