/dev-meetup-dimensionality-reduction

Jupyter Notebooks to demonstrate Factor Analysis (FA), t-distributed stochastic neighbor embedding (t-SNE) and Auto Encoders (AE)

Primary LanguageJupyter Notebook

dev-meetup-dimensionality-reduction

Jupyter Notebooks to demonstrate Factor Analysis (FA), t-distributed stochastic neighbor embedding (t-SNE) and Auto Encoders (AE)

Factor Analysis (FA)

The factor Analysis examples are a mix of the following three different blog posts:

  1. How to do factor analysis by Nick Elprin: this uses the standard R 'Psych' package.
  2. Fitting a Bayesian Factor Analysis Model in Stan by Rick Farouni: replicates the model in Stan.
  3. Probabilistic Factor Analysis Methods by Suleiman A. Khan & Joseph H. Sakaya: uses the ADVI (Automatic Variational Inference in Stan) inference method rather than MCMC sampling and combines the model with ARD (Automatic Relevance Determination, see chapter 13.7 "Automatic relevance determination (ARD)/sparse Bayesian learning (SBL)" of Machine Learning: A Probabilistic Perspective) to automatically detect the number of latent dimensions.

The below notebooks are translations of the above examples to python plus some additional features that I thought were missing from the above, e.g. an evaluation of the quality of the fit.