I there any built in tool in MATLAB that perform Principle Component Analysis?

4 views (last 30 days)
Hi
I am fairly new with PCA and Matlab.
I am trying to perform principle component analysis to reduce a data set that have 18 features to the 2 or 3 principle components and then using them to build clusters to classify several faults in a system. I have 270 samples for each feature. I have 10 faults, each 27 samples represent a specific fault in the system.
I am planning to train and test the algorithm to make sure that my algorithm can identify theses faults. It is very important for me that I get all the factors that are used in the linear correlation to calculate the first, second and third principle components so that after building my cluster I can use them to calculate the principle components when receiving the 18 features from the system then see in which cluster they belong.
I am trying write a code that calculates all the matrices from scratch to do PCA, but if there is any built in tool in Matlab for PCA, it will save me a lot of time.
Is there any? and if so is there any tutorials on how to use it?
Thanks in advance.

Accepted Answer

Thorsten
Thorsten on 9 Sep 2015
Edited: Thorsten on 9 Sep 2015
Matlab's PCA is called
princomp
You can find out using
lookfor principal
Which results in my system in
pcacov - Principal Components Analysis (PCA) using a covariance matrix.
pcares - Residuals from a Principal Components Analysis (PCA).
princomp - Principal Components Analysis (PCA) from raw data.
orthoregdemo - Fitting an Orthogonal Regression Using Principal Components Analysis
pcrsse - SSE for Principal Components Regression cross-validation.
plspcrdemo - Partial Least Squares Regression and Principal Components Regression

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!