Hi Matt,
As per my understanding, you would like to know how does "canoncorr" function selects the observations to set to 0 if input matrix is not a full rank matrix. I am assuming that:
- Observations are the individual data points or samples in the dataset i.e. 50,000 observations.
- Variables are the different measurements or features recorded for each observation i.e. 93 variables.
"canoncorr" function does not randomly set observations to zero for the coefficients matrix. It systematically computes the canonical coefficients for the variables, and any zeros in the coefficients matrices correspond to variables that are linearly dependent on others.
Please refer to the following MathWorks documentation for more information on "canoncorr" function:
Hope this helps!