Exercise:PCA in 2D
From Ufldl
(→Step 1b: Check xRot) |
(→Step 2: Dimension reduce and replot) |
||
Line 32: | Line 32: | ||
=== Step 2: Dimension reduce and replot === | === Step 2: Dimension reduce and replot === | ||
- | In the next step, set <math>k</math>, the number of components to retain, to be 1 (we have already done this for you). Compute the resulting < | + | In the next step, set <math>k</math>, the number of components to retain, to be 1 (we have already done this for you). Compute the resulting <tt>xHat</tt> and plot the results. You should get the following (this figure should '''not''' be flipped along the <math>\textstyle x</math>- or <math>\textstyle y</math>-axis): |
[[File:pca_xhat_2d.png|400px]] | [[File:pca_xhat_2d.png|400px]] |