CORREL Function
Pearson correlation coefficient between two arrays.
Syntax
Parameters
| Parameter | Description | Required |
|---|---|---|
| array1 | The first set of independent (or paired) numeric values. | Required |
| array2 | The second set of numeric values, the same length as array1. | Required |
Basic Example
Correlation between two paired series
=CORREL({2,3,5,7,9},{1,2,3,4,5})The two series move closely together; the coefficient is near 1, indicating a strong positive linear relationship.
Advanced Examples
Example 1: Correlation from ranges
Comparing advertising spend to salesBoth ranges must have the same number of points
=CORREL(B2:B13,C2:C13)Example 2: Negative relationship
Price versus demandHigher price tends to lower demand
=CORREL(A2:A20,B2:B20)How CORREL Works
CORREL computes r = Σ((x - x̄)(y - ȳ)) / sqrt(Σ(x - x̄)² · Σ(y - ȳ)²), where x̄ and ȳ are the means. The result always lies between -1 and 1: 1 is a perfect positive linear relationship, -1 a perfect negative one, and 0 no linear relationship. Text, logicals, and empty cells are ignored in each array.
Important Notes & Limitations
Measures only linear association; it can be near 0 even when a strong non-linear relationship exists.
Both arrays must contain the same number of data points, or #N/A is returned.
If either array has zero variance (all identical values), the function returns #DIV/0!.
Common Errors & Fixes
#N/AThe two arrays have different numbers of data points.Fix: Make sure array1 and array2 are the same length.
#DIV/0!One of the arrays has no variance (all values equal).Fix: Use data with variation, or check for constant columns.
Download Practice File
CORREL
correlPractice CORREL with Real Data
Download a sample CSV file with pre-populated data and practice exercises for the CORREL function. Works in both Excel and Google Sheets.
File format: CSV (comma-separated values) - opens in Excel, Google Sheets, and all spreadsheet apps