09-15-2014 04:36 PM
I want to calculate Polychoric correlation by using PROC CORR. My code is
proc corr data=adbttforcfa POLYCHORIC;
var adbtt_dom_1b adbtt_dom_2b adbtt_dom_3b adbtt_dom_4b adbtt_dom_5b adbtt_dom_6b adbtt_dom_7b adbtt_dom_8b;
title 'correlation for items of factor isolated';
But it failed, SAS log showed error message like:
20 proc corr data=adbttforcfa POLYCHORIC;
ERROR 22-322: Syntax error, expecting one of the following: ;, (, ALPHA, BEST, COV, CSSCP, DATA, EXCLNPWGT, FISHER, HOEFFDING,
KENDALL, NOCORR, NOMISS, NOPRINT, NOPROB, NOSIMPLE, OUTH, OUTK, OUTP, OUTS, PEARSON, PLOTS, POLYSERIAL, RANK,
SINGULAR, SPEARMAN, SSCP, VARDEF.
ERROR 202-322: The option or parameter is not recognized and will be ignored.
521 var adbtt_dom_1b adbtt_dom_2b adbtt_dom_3b adbtt_dom_4b adbtt_dom_5b adbtt_dom_6b adbtt_dom_7b adbtt_dom_8b;
522 title 'correlation for items of factor isolated';
What is the reason?? PROC CORR cannot produce Polychoric correlation?
09-15-2014 04:49 PM
What version of SAS are you using? POLYCHORIC definitely works in 9.3 and 9.4. I don't know when it was added (it was not in old version 8).
09-15-2014 04:52 PM
OTE: Copyright (c) 2002-2010 by SAS Institute Inc., Cary, NC, USA.
NOTE: SAS (r) Proprietary Software 9.3 (TS1M1)
Licensed to UNIV OF MASSACHUSETTS MEDICAL SCHOOL - SFA T&R, Site 70118457.
NOTE: This session is executing on the X64_7PRO platform.
09-15-2014 04:56 PM
Looks like the option only appeared with STAT 12.1 (or later), which was still part of 9.3. Your version (TS1M1) doesn't have it. I just checked. You will need a newer version of SAS for this.
09-16-2014 01:09 PM
Hi~ Proc freq can give me polychoric correlation. However, I have more than two variables, therefore I want to get a correlation matrix...But it seems like PROC FREQ cannot make the matrix...Do you have any idea to solve it? Thank you in advance!