Note: some features may need SAS 9.2 IMLplus
matrix A is a given COV. x1, x2, x3 (col1 col2 col3) are randomly generated having the given COV.
proc iml;
A = {25 0 5,
0 4 6,
5 6 59};
U = root(A);
print U;
call randseed(2);
x1=j(500000,1);
x2=x1;
x3=x1;
call randgen(x1, 'normal');
call randgen(x2, 'normal');
call randgen(x3, 'normal');
z=(x1||x2||x3)*U;
para={'col1', 'col2','col3'};
para={'col1' 'col2' 'col3'};
create t from z;
append from z;
close t;
submit para;
proc corr data=t cov;
var ¶ ;
run;
endsubmit;
quit;