Typical workflow for PCA - 5.2 English - 68552

AOCL API Guide (68552)

Document ID
68552
Release Date
2025-12-29
Version
5.2 English

The standard way of computing the principal component analysis using AOCL-DA is as follows.

  1. Initialize a aoclda.factorization.PCA() object with options set in the class constructor.

  2. Compute the PCA for your data matrix using aoclda.factorization.PCA.fit().

  3. Perform further transformations in necessary using aoclda.factorization.PCA.transform() or aoclda.factorization.PCA.inverse_transform().

  4. Extract results from the aoclda.factorization.PCA() object via its class attributes.

  1. Initialize a da_handle with da_handle_type da_handle_pca.

  2. Pass data to the handle using da_pca_set_data_?.

  3. Set the number of principal components required and the type of PCA using da_options_set_? (see below).

  4. Compute the PCA using da_pca_compute_?.

  5. Perform further transformations as required, using da_pca_transform_? or da_pca_inverse_transform_?.

  6. Extract results using da_handle_get_result_?.