Canonical correlation analysis

Multivariate analysis · Method and input reference

Numeric complete observations. PCA standardizes variables; EFA uses maximum likelihood without rotation. CFA accepts measurement lines only. Discriminant analysis uses first column as class; reports leave-one-out accuracy. Canonical correlation splits columns into two sets. Synthetic example: 180 people with two predictor-domain and two outcome-domain measures; the first two columns form set X.

Open calculator · Compare methods in the decision matrix

When to consider it

  • Explore linear associations between two sets of numeric variables.

Assumptions and scope

  • Observations must be independent between subjects; repeated rows from one subject are not independent samples.
  • Use the outcome and predictor coding required by the calculator; review missing data and model diagnostics.

Required inputs

  • Data matrix (one observation per line; comma-separated columns) — Numeric observations; preserve the row and column structure described above.
  • Number of columns in first variable set — Enter the method parameter described above.

Review missing values and data coding before running. Sample inputs are synthetic teaching examples.

Implementation

Lifescio canonical correlation through QR decomposition of standardized variable sets and singular-value decomposition; scikit-learn standardizes observations.

  • numpy 2.2.6: numpy.linalg.qr, numpy.linalg.svd

These are pinned library versions; saved results record the versions actually used at runtime.

Library references