you can certainly get PCA code from the software packaged with the books of jackson&staunton and alexander.they include other time series stuff too - ARIMA, GARCH, etcthe rest should be easiest to find.
Linear regressions can be done with linest() and don't need VBAFor PCA you can use the eigenvalue functions in the Quantlib xll.As you can see, I try to avoid VBA when possible ans stick to functions on the page...