Princomp and prinqual give the same proportions every time I have ever tested them.
proc princcomp data=sashelp.heart;
ods select eigenvalues;
run;
ods graphics on;
ods html body='b.html';
proc prinqual data=sashelp.heart out=res scores mdpref;
ods output mdprefplot=m;
var ide(_numeric_);
run;
ods html close;
proc contents varnum data=m; ods select position; run;
While I have not added it to the procedure at this juncture, I have grown fond of minimizing the data ink associated with the vectors. See this blog. It might not help much with hundreds of vectors.
Here is my blog that was inspired by this question.
Since prinqual typically iterates, it tries to get rid of potentially problematic variables. You can specify a really small singularity criterion as in this example.
data x;
do i = 1 to 10;
x1 = normal(7);
x2 = normal(7);
x3 = normal(7);
x4 = normal(7);
x5 = normal(7) * 1e-10;
output;
end;
run;
proc prinqual data=x std;
var ide(x:);
run;
proc prinqual data=x std singular=1e-50;
var ide(x:);
run;
You can always output anything produced by any procedure and rearrange it in any way to make a graph. Do an ODS OUTPUT on the data object that underlies prinqual's graph. Then use princomp pieces to make something like that. Again be aware that prinqual scales things in a nice way. The documentation has details.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.