| Cv2PCAComputeVar Method (InputArray, InputOutputArray, OutputArray, Double) |
PCA of the supplied dataset.
Namespace:
OpenCvSharp
Assembly:
OpenCvSharp (in OpenCvSharp.dll) Version: 1.0.0
Syntax public static void PCAComputeVar(
InputArray data,
InputOutputArray mean,
OutputArray eigenvectors,
double retainedVariance
)
Public Shared Sub PCAComputeVar (
data As InputArray,
mean As InputOutputArray,
eigenvectors As OutputArray,
retainedVariance As Double
)
public:
static void PCAComputeVar(
InputArray^ data,
InputOutputArray^ mean,
OutputArray^ eigenvectors,
double retainedVariance
)
static member PCAComputeVar :
data : InputArray *
mean : InputOutputArray *
eigenvectors : OutputArray *
retainedVariance : float -> unit
Parameters
- data
- Type: OpenCvSharpInputArray
input samples stored as the matrix rows or as the matrix columns. - mean
- Type: OpenCvSharpInputOutputArray
optional mean value; if the matrix is empty (noArray()), the mean is computed from the data. - eigenvectors
- Type: OpenCvSharpOutputArray
eigenvectors of the covariation matrix - retainedVariance
- Type: SystemDouble
Percentage of variance that PCA should retain.
Using this parameter will let the PCA decided how many components to retain but it will always keep at least 2.
See Also