+ Reply to Thread
Results 1 to 7 of 7

How to Use CORREL Function with Non-Contiguous Arrays

  1. #1
    Forum Contributor
    Join Date
    12-16-2014
    Location
    Riverside, IA
    MS-Off Ver
    2010
    Posts
    156

    How to Use CORREL Function with Non-Contiguous Arrays

    Hello,

    The following formula yielded a correlation of only 20% and my gut tells me it should be significantly higher:

    =CORREL(AX37:AZ37,AX44:AZ44)+CORREL(AN37:AO37,AN44:AO44)+CORREL(Z37:AK37,Z44:AK44)

    I can't relocate the cells so that all arrays are adjacent so that is not an option.

    Thank you,

    Patrick

  2. #2
    Forum Expert
    Join Date
    05-20-2015
    Location
    Chicago, Illinois
    MS-Off Ver
    2016
    Posts
    2,103

    Re: How to Use CORREL Function with Non-Contiguous Arrays

    Your current formula will simply sum the three separate correlations, which probably isn't what you want. You can combine non-contiguous arrays into a range using an array formula, but you still need a way to distinguish which columns in the large array (Z37:AZ37) should be counted. Do all of the columns to be included share a header? Are they the only columns with numeric data?

    For example, if the columns to be omitted are blank or contain text and the columns to be included are all positive values, you could use something like the following, array-entered (confirmed with Ctrl + Shift + Enter instead of Enter):

    =CORREL(IF(Z37:AZ37>0,Z37:AZ37),IF(Z44:AZ44>0,Z44:AZ44))

    It's hard to craft something more specific to your data without a sample workbook to look at. If you're still having difficulty, please post a sample with all private data altered or removed.
    If your problem has been solved, please use "Thread Tools" to mark the thread as "Solved".

    If you're grateful for this site's existence and would like to contribute to the community, please consider posting something hilarious in our joke thread:
    https://www.excelforum.com/the-water...ke-thread.html

  3. #3
    Forum Expert
    Join Date
    05-20-2015
    Location
    Chicago, Illinois
    MS-Off Ver
    2016
    Posts
    2,103

    Re: How to Use CORREL Function with Non-Contiguous Arrays

    Here's an alternative that's hard-coded to specifically avoid columns 38,39, and 43-49. It should be array-entered:

    =CORREL(IF(ISNA(MATCH(COLUMN(Z37:AZ37),{38,39,43,44,45,46,47,48,49},0)),Z37:AZ37),IF(ISNA(MATCH(COLUMN(Z44:AZ44),{38,39,43,44,45,46,47,48,49},0)),Z44:AZ44))

    Maybe that'll work better?

  4. #4
    Forum Contributor
    Join Date
    12-16-2014
    Location
    Riverside, IA
    MS-Off Ver
    2010
    Posts
    156

    Re: How to Use CORREL Function with Non-Contiguous Arrays

    CAntosh,

    Thank you for the alternate formula! However, it derived a negative correlation of -.81 and it should have been a positive. Let me try another idea to get the desired result and I will update my results shortly.

  5. #5
    Forum Expert
    Join Date
    05-20-2015
    Location
    Chicago, Illinois
    MS-Off Ver
    2016
    Posts
    2,103

    Re: How to Use CORREL Function with Non-Contiguous Arrays

    Quote Originally Posted by EverClever View Post
    I will update my results shortly.
    Sounds good! A sample workbook would be a necessity if you're still having issues.

  6. #6
    Forum Contributor
    Join Date
    12-16-2014
    Location
    Riverside, IA
    MS-Off Ver
    2010
    Posts
    156

    Re: How to Use CORREL Function with Non-Contiguous Arrays

    CAntosh,

    Your formula worked! My alternate formula also worked as it got the same result!

    Thank you much for your expertise!!!

    Patrick

  7. #7
    Forum Expert
    Join Date
    05-20-2015
    Location
    Chicago, Illinois
    MS-Off Ver
    2016
    Posts
    2,103

    Re: How to Use CORREL Function with Non-Contiguous Arrays

    Excellent, glad to help. Thanks for the rep!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. correl function and div/0
    By Alfie101 in forum Excel General
    Replies: 2
    Last Post: 03-29-2016, 03:11 AM
  2. XIRR for non contiguous arrays
    By Alexander_Golinsky in forum Excel General
    Replies: 3
    Last Post: 07-13-2012, 05:15 AM
  3. [SOLVED] XIRR for non contiguous arrays
    By Alexander_Golinsky in forum Excel General
    Replies: 1
    Last Post: 07-12-2012, 12:06 PM
  4. correl function
    By censura in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 07-18-2007, 05:13 AM
  5. [SOLVED] Can I correlate 4 arrays e.g =correl(C7:C21,D7:D21,E7:E21,F7:F21
    By peaceful k in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-31-2006, 02:10 AM
  6. [SOLVED] Using CORREL with arrays containing null values
    By rmellison in forum Excel General
    Replies: 1
    Last Post: 11-11-2005, 11:10 AM
  7. [SOLVED] Can I "CORREL" statistical funtion with three or more Arrays?
    By juanes in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-04-2005, 09:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1