drcme.spca.consolidate_spca

drcme.spca.consolidate_spca(spca_results, adj_exp_var_threshold=0.01)[source]

Combine and z-score individual data set sPCs into single matrix

Parameters
  • spca_results (dict) – Dictionary of loadings, adjusted explained variances, and transformed values

  • adj_exp_var_threshold (float, optional) – Minimum adjusted explained variance level (default 0.01) to retain sPCs

  • Returns

  • combined_matrix ((n_samples, n total sPCs) array) – Z-scored matrix of all sPC-transformed values

  • component_record (list) – List of kept component information for each key of spca_results