-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e05a7a5
commit 057f47d
Showing
2 changed files
with
95 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
--- | ||
title: 'Algorithm: Principal components analysis (PCA)' | ||
date: 2024-03-01 | ||
permalink: /posts/2024/03/blog-algorithm-001/ | ||
author_profile: true | ||
tags: | ||
- Point Cloud | ||
- Algorithm | ||
--- | ||
|
||
Original paper: Hotelling, Harold. "Analysis of a complex of statistical variables into principal components." Journal of educational psychology 24.6 (1933): 417. [https://doi.org/10.1037/h0071325](https://doi.org/10.1037/h0071325) | ||
|
||
This is a record of the reading process, aimed at personal learning, reading and writing practicing. | ||
|
||
- [Abstract](#abstract) | ||
- [1 Introduction](#1-introduction) | ||
- [1.1 Related Work](#11-related-work) | ||
- [1.1.1 Methods in Computational Forestry producing QSMs of the Branching Structure](#111-methods-in-computational-forestry-producing-qsms-of-the-branching-structure) | ||
- [1.1.2 Methods in Computer Vision producing QSMs of the Branching Structure](#112-methods-in-computer-vision-producing-qsms-of-the-branching-structure) | ||
- [1.1.3 Further Open Source Tree Modelling Software and Point Cloud Processing Libraries](#113-further-open-source-tree-modelling-software-and-point-cloud-processing-libraries) | ||
- [1.2 Relevance of the Presented Work in the State of the Art](#12-relevance-of-the-presented-work-in-the-state-of-the-art) | ||
- [1.3 Structure of the Manuscript](#13-structure-of-the-manuscript) | ||
- [2 Software—SimpleTree](#2-softwaresimpletree) | ||
- [2.1. Filter and Clustering Routines](#21-filter-and-clustering-routines) | ||
|
||
|
||
* PCA(主成分分析)是一种用于降维和数据可视化的技术,它通过线性变换将数据投影到一个新的坐标系中,以便使得数据的方差在新坐标系下被最大化。 | ||
|
||
|
||
**主成分分析(PCA)** | ||
**基本原理:** | ||
|
||
PCA的基本思想是将原始数据投影到一个新的坐标系中,使得投影后的数据在各个坐标轴上的方差尽可能大,从而保留数据中的大部分信息。具体步骤如下: | ||
|
||
1. 计算数据的协方差矩阵。 | ||
2. 对协方差矩阵进行特征值分解,得到特征值和对应的特征向量。 | ||
3. 将特征向量按照特征值大小降序排列,选取其中方差最大的前几个特征向量作为新的坐标轴。 | ||
4. 将原始数据投影到选取的特征向量构成的新的低维空间中。 | ||
|
||
**应用:** | ||
|
||
- 降维:PCA可以用于降低数据的维度,保留数据中的主要信息,从而减少计算量和存储空间。 | ||
- 数据可视化:通过将高维数据映射到二维或三维空间中,可以更容易地对数据进行可视化分析。 | ||
- 去噪:PCA可以帮助去除数据中的噪声,保留数据中的信号部分。 | ||
- 特征提取:PCA可以用于提取数据中的主要特征,从而更好地理解数据的结构和特点。 | ||
|
||
**算法步骤:** | ||
|
||
1. 标准化数据:将原始数据按列进行标准化处理,使得每个特征的均值为0,方差为1。 | ||
2. 计算协方差矩阵:对标准化后的数据计算协方差矩阵。 | ||
3. 特征值分解:对协方差矩阵进行特征值分解,得到特征值和对应的特征向量。 | ||
4. 选取主成分:根据特征值的大小,选取前几个特征向量作为主成分。 | ||
5. 数据投影:将原始数据投影到选取的主成分构成的新的低维空间中。 | ||
|
||
**注意:** | ||
|
||
- 数据的标准化对PCA的结果影响很大,需要在进行PCA之前对数据进行标准化处理。 | ||
- PCA对数据的线性关系敏感,如果数据存在非线性关系,PCA可能无法有效提取数据的结构信息。 | ||
- 选择合适的主成分数量是一个重要的问题,通常可以通过保留一定比例的方差来确定主成分的数量。 | ||
|
||
|
||
|
||
|
||
|
||
|