PCA Class Reference
Principal Component Analysis.
More...
#include <pca.h>
List of all members.
Detailed Description
Principal Component Analysis.
Constructor & Destructor Documentation
PCA::PCA |
( |
double ** |
data = 0 , |
|
|
int |
rows = 0 , |
|
|
int |
cols = 0 | |
|
) |
| | |
Constructor
- Parameters:
-
| data | the data coordinates |
| rows | number of rows |
| cols | number of columns |
| datasets | number of datasets |
Member Function Documentation
void PCA::GetCumulativeVariance |
( |
vector< double > * |
cumvar |
) |
|
Get the vector with cumulative variance explained by each eigenvalue
- Returns:
- the vector of cumulative variance
void PCA::GetEigenvalues |
( |
vector< double > * |
eigenvalues |
) |
|
Get the vector with eigenvalues
- Returns:
- the eigenvalues
void PCA::GetEigenvectors |
( |
vector< vector< double > > * |
eigenvectors |
) |
|
Get the vector with eigenvectors
- Returns:
- the eigenvectors
void PCA::GetMean |
( |
vector< double > * |
mean |
) |
|
Get the vector with mean values
- Returns:
- the vector of means
void PCA::GetPCLoadings |
( |
Matrix< double > * |
loadings |
) |
|
Get PC loadings
- Returns:
- the PC loadings
void PCA::GetPCScores |
( |
Matrix< double > * |
scores |
) |
|
Get PC scores
- Returns:
- the PC scores
void PCA::GetVariance |
( |
vector< double > * |
var |
) |
|
Get the vector with variance explained by each eigenvalue
- Returns:
- the vector of variance
bool PCA::IsCalculated |
( |
|
) |
|
Has PCA been performed
- Returns:
- true if PCA analysis has been performed on our data
void PCA::LoadData |
( |
double ** |
data, |
|
|
int |
rows, |
|
|
int |
cols | |
|
) |
| | |
LoadData
- Parameters:
-
| data | the data coordinates |
| rows | number of rows |
| cols | number of columns |
void PCA::PerformPCA |
( |
bool |
center = true , |
|
|
bool |
scale = false | |
|
) |
| | |
Perform Principal Component Analysis on our data
- Parameters:
-
| center | center data, subtract the mean of each column |
| scale | scale data, divide with root mean square of each column |
The documentation for this class was generated from the following files:
- M:/evan/GMMlib/inc/pca.h
- M:/evan/GMMlib/src/pca.cpp