MATH 494: Mathematical Foundations of Machine Learning
Assignment #8
(Due Wednesday, April 17, 2024)
This is the second of the two assignments in unsupervised learning. I believe this one is WAY easier than the deeply traumatic Assignment #7.
You will perform the PCA procedure on a noisy dataset and show that your results are exactly the same as those obtained by sklearn's PCA (and numpy's SVD).
What you need to do:
· Generate exactly the same noisy dataset as you created in Assignment #7.
· Center the dataset (essential!)
· "Perform PCA by hand", that is, use numpy.linalg.eig() to find the eigenvalues and eigenvectors.
· Determine and display the amounts/proportions of variance of the data represented by each principal component.
· Perform PCA with the sklearn's PCA procedure.
· Perform SVD with the numpy's SVD procedure.
· Show that each of the three methods produces virtually identical singular values.