BookmarkSubscribeRSS Feed
SOORISAS
Calcite | Level 5

I have a problem with Correlation matrix output.

As in the attached excel, this is my correlation matrix output dataset.

Please igore the yellow highlighted, as it is the replica and the red part, it is the correlation of same variables.

My interest is in the below the non-highlighted area.

My requirement,

B*A =.98

C*A=.98

Then it is obvious that B*C=.98. So, if that is the case I dont want this to be populated as .98, instead it should be populated as NULL or someother numeric value.

Basically i dont want the redundant correlation. Like this I have a 300*300 matrix. I think this is a complex problem, but your help is much appreciated.

4 REPLIES 4
gergely_batho
SAS Employee

This is not redundant information.

You can calculate upper and lower bounds for corr(B,C) from corr(A,B) and corr(A,C), but not the exact value.

PaigeMiller
Diamond | Level 26

Then it is obvious that B*C=.98.

I don't think this is a true statement, I'm pretty sure that the correlation B*C can be numbers other than 0.98, and so I don't see how to proceed with the rest of your request, nor do I think it reasonable at this time to continue with the rest of your request.

--
Paige Miller
Rick_SAS
SAS Super FREQ

If B=C, then corr(B,C)=1.

stat_sas
Ammonite | Level 13

Hi,

Why not eliminate redundant variables first using some data reduction technique? This will automattically eliminate redundant correlation.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 4 replies
  • 596 views
  • 0 likes
  • 5 in conversation