the covariance parameters are provided with se's, but it does not seem obvious if you can get the se's for the elements of the correlation matrix resulting from rcorr on the repeated statement (they are not provided in the rcorr ods). Are they available or can they be calculated by hand? You don't often see variance components presented with confidence intervals
"So, is your issue that the CIs are given only for the covariances and not for the correlations?"
yes, i have repeated this in literally all of the above posts 🙂
i'm beginning to think the se can't be obtained for the correlation estimates, although I'm pretty sure both R and STATA can provide them, i wonder why SAS doesn't.
You can use the CL option on the PROC MIXED statement to get confidence intervals for the covariance parameters. The confidence limits are displayed as extra columns in the "Covariance Parameter Estimates" table. You can use the COVTEST option to get asymptotic standard errors. See this page of the doc: SAS Help Center: PROC MIXED Statement
If that doesn't answer your question, please show the statements that you are using.
Thanks Rick. It's the same code in this paper: Analyzing Multivariate Longitudinal Data Using SAS
proc mixed data=CRISP_MIX covtest noclprint; title1 "Model 1.1 Mixed model with a Kronoker product covariance"; title2 "KVS (X) versus CVS (Y)"; class pkdid vname visitc; model val=vname*visit/s noint; repeated vname visitc /type=un@ar(1) subject=pkdid r rcorr; where vname="KVS" or vname="CVS"; run;
they display the correlations resulting from this model in the middle portion of the table
the SAS output displays se's for the cov parameters, but not for these correlation estimates. I wonder if they are obtainable
OK. So what happens if you add the CL option to the PROC MIXED statement?
Unfortunately the CI is not displayed when i add cl to the mixed statement. The correlations are presented in the output and in the rcorr ods in matrix form (making it tough to display the corresponding CIs), whereas the covariance parameters are displayed in a table, allowing the CIs to be presented alongside them. I can't show my particular output but it's exactly as seen in figures 32 and 33 here: https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/statug/statug_mixed_examples02.htm. Thanks
edit: actually, it's not exactly like figure 32 because it is the correlation matrix, the heading looks like this:
For the example in the doc, if I add the CL option on the PROC MIXED statement, the output includes the confidence limits. However, perhaps the issue is that the CIs are not added to the R table ("Estimated R Matrix for Person 1") but to the CovParms table ("Covariance Parameter Estimates")? If you are using an ODS SELECT or ODS OUTPUT statement, make sure you are capturing the CovParms table. Here is the doc example with the CL option and an ODS statement that selects only the R and CovParms tables:
proc mixed data=pr method=ml covtest CL;
class Person Gender;
model y = Gender Age Gender*Age / s;
repeated / type=un subject=Person r;
ods select R CovParms;
run;
*UPDATE*: I see that you changed your last response. You are now using the RCORR option on the REPEATED statement and are looking at the RCORR ODS table. So, is your issue that the CIs are given only for the covariances and not for the correlations?
"So, is your issue that the CIs are given only for the covariances and not for the correlations?"
yes, i have repeated this in literally all of the above posts 🙂
i'm beginning to think the se can't be obtained for the correlation estimates, although I'm pretty sure both R and STATA can provide them, i wonder why SAS doesn't.
I'm sorry if my questions have frustrated you. I was just trying to understand the issue. Perhaps one of the other experts will be able to answer your questions. Good luck!
If your errors are approximately normally distributed, you can use the value applied in the Fisher transformation of a correlation to a z-score. In the asymptotic case, this standard error is 1/sqrt(n-3), where n is the number of observations used.
SteveDenham
(Gotta admit this is something of a straw man answer, but it might stimulate some discussion).
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.