Output discrepancy between SAS and R -


i have coded same program in r , in sas (university edition running on oracle virtualbox on mac) , i'm noticing discrepancy - means messed up.

the first discrepancy appears in principal component analysis run , believe has options intrinsic functions available in 2 programs. diligently working on looking on documentation grateful assistance of brilliant experts on site.

i have been using file - https://drive.google.com/file/d/0b9oqam9ykac3bepicestrw8wuzg/view?usp=sharing - test 2 programs.

in r, code pca simple:

pca1=prcomp(predictor_matrix, scale.=true) 

and first observation transformed following

<1.01,  -0.79,  -0.03,  -1.08,  1.86,    -0.13,  0.04,   -0.03,  0.02,   -0.01> 

in sas, code pca looks like:

proc factor data=regressors      simple corr     mineigen=0 /*retain eigenfunctions*/     nfactors=10      /*print optional data*/     out=newdata /*get transformed data*/      ; run; 

and first observation transformed following

<0.55,  -0.53,  -0.02,  -0.89,  1.96,    1.45,   0.89    ,    1.18,  1.15,   1.46> 

now - eigenvector matrices identical in both programs eigenvalues different, i'm thinking problem has scaling. brand new sas , use pointers on how results of these 2 programs converge.

the sas proc pca proc princomp, not proc factor. try

proc princomp data=regressors n=10 out=newdata; run; 

Comments

Popular posts from this blog

c++ - No viable overloaded operator for references a map -

java - Custom OutputStreamAppender not run: LOGBACK: No context given for <MYAPPENDER> -

java - Cannot secure connection using TLS -