Skip to Content
面向数据科学家的实用统计学
book

面向数据科学家的实用统计学

by Peter Bruce, Andrew Bruce
October 2018
Beginner to intermediate
238 pages
6h 32m
Chinese
Posts & Telecom Press
Content preview from 面向数据科学家的实用统计学
194
|
第
7
章
主成分分析最早是由卡尔
•
皮尔逊(
Karl Pearson
)在
1901
年发表的一篇论文中提出的。
这篇论文可能是首篇公开发表的无监督学习论文。皮尔逊在论文中指出,在许多问题中,
预测变量存在变异性,因此他提出了对该变异性建模的主成分分析技术。主成分分析可以
看成一种无监督版的线性判别分析(参见
5.2
节 )。
7.1.1
 一个简单的例子
对于两个变量
X
1
和
X
2
,具有两个主成分
Z
i
(
i
= 1, 2
):
Z
i
= w
i
,1
X
1
+ w
i
,2
X
2
其中,权重
w
i
,1
和
w
i
,2
被称为成分
载荷
,用于将原始变量转换为主成分。第一主成分
Z
1
最
好地解释了总变异性的线性组合。第二主成分
Z
2
解释了剩余的变异性,它也是最差拟合的
线性组合。
还有一种常用的主成分计算方法。该方法使用了预测变量与均值之间的偏离
情况,而非预测变量本身。
在
R
语言中,可以使用函数 princomp 计算主成分。下面的代码对雪佛龙公司(
CVX
)和
埃克森美孚公司(
XOM
)的股票收益做了主成分分析。
oil_px <- sp500_px[, c('CVX', 'XOM')]
pca <- princomp(oil_px)
pca$loadings
Loadings:
Comp.1 Comp.2
CVX -0.747 0.665
XOM -0.665 -0.747
对于
CVX
和
XOM
的股票收益数据,第一主成分的权重分别是
-
0.747
和
-
0.665
,第二主
成分的权重分别是
0.665
和
-
0.747
。这个结果应该如何解释?第一主成分基本上是 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

基于Python的智能文本分析

基于Python的智能文本分析

Benjamin Bengfort, Rebecca Bilbro, Tony Ojeda
Python数据处理

Python数据处理

Jacqueline Kazil, Katharine Jarmul
精通機器學習

精通機器學習

Aurélien Géron
C++语言导学(原书第2版)

C++语言导学(原书第2版)

本贾尼 斯特劳斯特鲁普

Publisher Resources

ISBN: 9787115493668