当前位置:网站首页>数据降维——主成分分析
数据降维——主成分分析
2022-07-02 17:54:00 【路Lu727】
1、作用
主成分分析将多个有一定相关性的指标进行线性组合,以最少的维度解释原数据中尽可能多的信息为目标进行降维,降维后的各变量间彼此线性无关,最终确定的新变量是原始变量的线性组合,且越往后主成分在方差中的比重也小,综合原信息的能力越弱,与因子分析不同的是,因子分析是利用少数几个公共因子去解释较多个要观测变量中存在的关系,它不是对原始变量的重新组合。
2、输入输出描述
输入:2 个或两个以上的定量变量(假设为 N 个变量)
输出:最低可降维成 1 维(一个变量,一般用于综合评价),最多可降维成 N 个变量(一般用于数据脱敏),同时可以获取降维后各个变量的组成权重,用于代表原先变量的数据保留情况。
3、案例示例
现在某银行有一张100个变量的用户属性数据表,需要在保证数据的原有信息的损失率最小情况,进行脱敏与降维。

4、建模步骤
主成分分析法是运用“降维”思想,把多个指标 变换成少数综合指标的多元统计方法,这里的综合 指标就是主成分。每个主成分都是原始变量的线性组合,彼此相互独立,并保留了原始变量绝大部分信息。其本质是通过原始变量的相关性,寻求相关变 量的综合替代对象,并且保证了转化过程中的信息损失最小 。
根据标准化后的数据集计算协方差矩阵R:

计算矩阵 R 的特征值 λ1 ≥λ2 ≥…≥λn ≥ 0及 对应的特征向量 u1 ,u2 ,…,un ,其中 uj= (u1 j,u2 j, …,unj) ,u nj 表示第 j 个特征向量的第 n 个分量; 由特征向量组成 n 个新的指标变量:

式中,y 1 是第 1 主成分,y 2 是第 2 主成分,…,y n 是第 n 主成分。 计算各主成分y j 贡献率 b j(j=1,2,...,n) 及 y 1,y 2 ,…,y n (p ≤ n)的累计贡献率
。


边栏推荐
- Industrial software lecture - core technology analysis of 3D CAD design software - the second lecture of the Forum
- LightGroupButton* sender = static_cast<LightGroupButton*>(QObject::sender());
- 问题包含哪些环节
- Golang concurrent programming goroutine, channel, sync
- The difference between promise and observable
- Looking for innocence in New York -- a beautiful day at the discovery center of Legoland, New Jersey
- Troubleshooting: kubectl reports an error validationerror: unknown field \u00a0
- 徹底搞懂基於Open3D的點雲處理教程!
- Learn the knowledge points of eight part essay ~ ~ 1
- 【JVM调优实战100例】01——JVM的介绍与程序计数器
猜你喜欢

新手必看,点击两个按钮切换至不同的内容
![[100 cases of JVM tuning practice] 01 - introduction of JVM and program counter](/img/c4/3bba96fda92328704c2ddd929dcdf6.png)
[100 cases of JVM tuning practice] 01 - introduction of JVM and program counter

Google's official response: we have not given up tensorflow and will develop side by side with Jax in the future

How to copy and paste interlaced in Excel

Processing strategy of message queue message loss and repeated message sending

How can retail enterprises open the second growth curve under the full link digital transformation

Mysql高级篇学习总结7:Mysql数据结构-Hash索引、AVL树、B树、B+树的对比

深度学习数学基础
![[daily question] the next day](/img/8a/18329bd9b4a3a4445c8fbbc1ce562b.png)
[daily question] the next day

The text editor hopes to mark the wrong sentences in red, and the text editor uses markdown
随机推荐
Redis (6) -- object and data structure
电商系统中常见的 9 大坑,你踩过没?
【测试开发】一文带你了解什么是软件测试
Compile oglpg-9th-edition source code with clion
Page title component
[100 cases of JVM tuning practice] 02 - five cases of virtual machine stack and local method stack tuning
metric_logger小解
Talk about the design of red envelope activities in e-commerce system
[daily question] first day
预处理和预处理宏
Yesterday, Alibaba senior wrote a responsibility chain model, and there were countless bugs
Progress-进度条
How to play when you travel to Bangkok for the first time? Please keep this money saving strategy
Excel如何进行隔行复制粘贴
高频面试题
Excel查找一列中的相同值,删除该行或替换为空值
新加坡暑假旅游攻略:一天玩转新加坡圣淘沙岛
R语言使用epiDisplay包的lsNoFunction函数列出当前空间中的所有对象、除了用户自定义的函数对象
Introduction to sap s/4hana OData mock service
R language uses lrtest function of epidisplay package to perform likelihood ratio test on multiple GLM models (logisti regression). Compare whether the performance of the two models is different, and