mlpack_kernel_pca(1) | User Commands | mlpack_kernel_pca(1) |
mlpack_kernel_pca - kernel principal components analysis
mlpack_kernel_pca -i string -k string [-b double] [-c bool] [-D double] [-S double] [-d int] [-n bool] [-O double] [-s string] [-V bool] [-o string] [-h -v]
This program performs Kernel Principal Components Analysis (KPCA) on the specified dataset with the specified kernel. This will transform the data onto the kernel principal components, and optionally reduce the dimensionality by ignoring the kernel principal components with the smallest eigenvalues.
For the case where a linear kernel is used, this reduces to regular PCA.
For example, the following command will perform KPCA on the dataset ’input.csv' using the Gaussian kernel, and saving the transformed data to ’transformed.csv':
$ kernel_pca --input_file input.csv --kernel gaussian --output_file transformed.csv
The kernels that are supported are listed below:
The parameters for each of the kernels should be specified with the options ’--bandwidth (-b)', '--kernel_scale (-S)', '--offset (-O)', or '--degree (-D)' (or a combination of those parameters).
Optionally, the Nyström method ("Using the Nystroem method to speed up kernel machines", 2001) can be used to calculate the kernel matrix by specifying the ’--nystroem_method (-n)' parameter. This approach works by using a subset of the data as basis to reconstruct the kernel matrix; to specify the sampling scheme, the '--sampling (-s)' parameter is used. The sampling scheme for the Nyström method can be chosen from the following list: 'kmeans', 'random', ’ordered'.
For further information, including relevant papers, citations, and theory, consult the documentation found at http://www.mlpack.org or included with your distribution of mlpack.
18 November 2018 | mlpack-3.0.4 |