|
|
Line 54: |
Line 54: |
| | | |
| == 旋转数据 == | | == 旋转数据 == |
- | | + | 至此,我们可以把 <math>\textstyle x</math> 用 <math>\textstyle (u_1, u_2)</math> 基表达为: |
- | | + | |
- | 【原文】:Thus, we can represent <math>\textstyle x</math> in the <math>\textstyle (u_1, u_2)</math>-basis by computing
| + | |
| :<math>\begin{align} | | :<math>\begin{align} |
| x_{\rm rot} = U^Tx = \begin{bmatrix} u_1^Tx \\ u_2^Tx \end{bmatrix} | | x_{\rm rot} = U^Tx = \begin{bmatrix} u_1^Tx \\ u_2^Tx \end{bmatrix} |
| \end{align}</math> | | \end{align}</math> |
- | (The subscript "rot" comes from the observation that this corresponds to
| + | (下标“rot”来源于单词“rotation”,意指这是原数据经过旋转(也可以说成映射)后得到的结果) |
- | a rotation (and possibly reflection) of the original data.)
| + | |
- | Lets take the entire training set, and compute
| + | |
- | <math>\textstyle x_{\rm rot}^{(i)} = U^Tx^{(i)}</math> for every <math>\textstyle i</math>. Plotting this transformed data
| + | |
- | <math>\textstyle x_{\rm rot}</math>, we get:
| + | |
| | | |
- | 【初译】:因此,我们可以计算出以<math>\textstyle (u_1, u_2)</math>为基的<math>\textstyle x</math>的映射表示。
| + | 对数据集中的每个样本 <math>\textstyle i</math> 分别进行旋转: <math>\textstyle x_{\rm rot}^{(i)} = U^Tx^{(i)}</math> for every <math>\textstyle i</math> ,然后把变换后的数据 <math>\textstyle x_{\rm rot}</math> 显示在坐标图上,可得: |
- | :<math>\begin{align}
| + | |
- | x_{\rm rot} = U^Tx = \begin{bmatrix} u_1^Tx \\ u_2^Tx \end{bmatrix}
| + | |
- | \end{align}</math>
| + | |
- | (下标“rot”来源于单词“rotation”,意指这是原数据经过旋转(也可以说成映射)得到后得到的结果)数据集中的每个数据<math>\textstyle i</math>经过<math>\textstyle x_{\rm rot}^{(i)} = U^Tx^{(i)}</math>计算后,可以画出如下映射数据<math>\textstyle x_{\rm rot}</math>图:
| + | |
- | | + | |
- | 【一审】:由此,我们可以计算出以<math>\textstyle (u_1, u_2)</math>为基的<math>\textstyle x</math>的映射表示。
| + | |
- | :<math>\begin{align}
| + | |
- | x_{\rm rot} = U^Tx = \begin{bmatrix} u_1^Tx \\ u_2^Tx \end{bmatrix}
| + | |
- | \end{align}</math>
| + | |
- | (下标“rot”来源于单词“rotation”,意指这是原数据经过旋转(也可以说成映射)得到后得到的结果)数据集中的每个数据<math>\textstyle i</math>经过<math>\textstyle x_{\rm rot}^{(i)} = U^Tx^{(i)}</math>计算后,可以画出如下变换映射数据<math>\textstyle x_{\rm rot}</math>图:
| + | |
- | | + | |
- | 【二审】:因此,我们可以计算出<math>\textstyle x</math>在<math>\textstyle (u_1, u_2)</math>基上的映射表示。
| + | |
- | :<math>\begin{align}
| + | |
- | x_{\rm rot} = U^Tx = \begin{bmatrix} u_1^Tx \\ u_2^Tx \end{bmatrix}
| + | |
- | \end{align}</math>
| + | |
- | (下标“rot”来源于单词“rotation”,意指这是原数据经过旋转(也可以说成映射)后得到的结果)
| + | |
- | 对数据集<math>\textstyle x_{\rm rot}^{(i)} = U^Tx^{(i)}</math>中的每个<math>\textstyle i</math>取值经过计算后,根据变换后的数据<math>\textstyle x_{\rm rot}</math>作图,可得:
| + | |
| | | |
| [[File:PCA-rotated.png|600px]] | | [[File:PCA-rotated.png|600px]] |