Principal component analysis: pictures, code and proofs | Joel Laity

The code used to generate the plots for this post can be found here.