Need some help wih a Correlation formula

Dave L

Board Regular
Joined
Jun 19, 2003
Messages
87
I have the following formula which calculates the median for D6:D671 if certain conditions are met:

Median(IF(($B$6:INDIRECT("B"&$C$703)<=$F721)*($B$6:INDIRECT("B"&$C$703)>$G721),D$6:D$671))

What I would like to do is calculate the correlation between D$6:D$671 and another range E$6:E$671 if those same conditions are met, but I can't figure out the necessary changes to the formula to use the CORREL function.

Can anyone help me out on this?

Thanks,

Dave
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
Hi,

Try:

=CORREL(IF(($B$6:INDEX(B:B,$C$703)<=$F721)*($B$6:INDEX(B:B,$C$703)>$G721),D$6:INDEX(D:D,$C$703)),IF(($B$6:INDEX(B:B,$C$703)<=$F721)*($B$6:INDEX(B:B,$C$703)>$G721),E$6:INDEX(E:E,$C$703)))


Confirmed with Ctrl + shift + enter.
 
Upvote 0
fairwinds,

Thanks for your help. I didn't use your formula exactly because I had made some changes to what I was doing, but your suggestion helped me get it all straight and working properly.

Thanks again,

Dave
 
Upvote 0

Forum statistics

Threads
1,214,932
Messages
6,122,332
Members
449,077
Latest member
jmsotelo

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top