Tutorials › Introduction to Statistics › Correlation Is Symmetric, Not a Directional Effect

Scatterplots and Correlation · Tutorial 241 of 996

Correlation Is Symmetric, Not a Directional Effect

See how swapping the two variables leaves Pearson’s correlation unchanged, and why that makes correlation a measure of association rather than a way to assign variable roles.

Beginner 9 min read

What You'll Learn

  • Define Pearson’s correlation for paired quantitative observations.
  • Show algebraically why swapping the variables leaves the correlation unchanged.
  • Calculate a correlation and verify it after reversing the variable order.
  • Distinguish the symmetry of correlation from the choice of scatterplot axes.
  • Explain why correlation alone cannot identify a predictor or response role.

Why the Order of Two Variables Matters Less Than It Seems

A scatterplot places one variable on the horizontal axis and another on the vertical axis. That layout can make one variable look like an input and the other like an outcome. But the Pearson correlation coefficient itself does not privilege either variable: switching their order leaves the coefficient unchanged. The plot’s axis arrangement is a choice of display, not something the correlation calculation uses to assign roles.

This symmetry is useful when reading and reporting correlations. A value of \(r\) summarizes the direction and strength of a linear association between two quantitative variables. It does not tell us which variable should be treated as a predictor and which as a response. Those roles depend on the question and study context, not on the value of \(r\).

Definition: Pearson’s Correlation for Paired Data

Suppose we observe two quantitative variables on the same \(n\) individuals or units. Write the paired observations as \((x_1,y_1),\ldots,(x_n,y_n)\). Each \(x_i\) must stay matched with its corresponding \(y_i\); the two columns are not independent lists of values. For Pearson’s correlation to be defined, both variables must vary in the observed data, so neither \(s_x\) nor \(s_y\) is zero.

Definition: Pearson’s sample correlation, \(r_{xy}\), is the sum of the products of paired deviations from their respective sample means, divided by the square root of the product of the sums of squared deviations: $$ r_{xy} = \frac{\sum_{i=1}^{n}(x_i-\bar{x})(y_i-\bar{y})} {\sqrt{\left[\sum_{i=1}^{n}(x_i-\bar{x})^2\right] \left[\sum_{i=1}^{n}(y_i-\bar{y})^2\right]}}. $$

The subscripts \(xy\) indicate that the calculation pairs the \(x\)-values with the \(y\)-values. Reversing the subscripts gives \(r_{yx}\), calculated from the same pairs with the variables in the opposite order. The key question is whether those two calculations can differ.

Why Swapping the Variables Leaves \(r\) Unchanged

The numerator of the formula adds one product for each paired observation. When we reverse the order, each product changes from \((x_i-\bar{x})(y_i-\bar{y})\) to \((y_i-\bar{y})(x_i-\bar{x})\). Multiplication is commutative, so these are equal. The denominator also contains the same two sums of squares, just in the opposite order. Their product, and therefore its square root, remains the same.

$$ \begin{aligned} r_{yx} &= \frac{\sum_{i=1}^{n}(y_i-\bar{y})(x_i-\bar{x})} {\sqrt{\left[\sum_{i=1}^{n}(y_i-\bar{y})^2\right] \left[\sum_{i=1}^{n}(x_i-\bar{x})^2\right]}} \\[4pt] &= \frac{\sum_{i=1}^{n}(x_i-\bar{x})(y_i-\bar{y})} {\sqrt{\left[\sum_{i=1}^{n}(x_i-\bar{x})^2\right] \left[\sum_{i=1}^{n}(y_i-\bar{y})^2\right]}} \\[4pt] &= r_{xy}. \end{aligned} $$

This is a complete algebraic reason for the symmetry: no assumption about a population distribution is needed to establish it. It follows directly from the formula. If the correlation is positive in one order, it is positive in the other; if it is negative, it remains negative; and its magnitude is unchanged.

Worked Example: Reversing the Order for a Positive Correlation

For a small, hypothetical set of four observations, let \(x\) be the number of practice sessions and \(y\) be a score on a short practice task. The observed pairs are \((1,2),(2,4),(3,5),(4,7)\). Calculate the correlation in each order.

The observations are paired, both variables are quantitative, and both vary. The means are \(\bar{x}=2.5\) sessions and \(\bar{y}=4.5\) points. The deviations are:

For \(x\): \(-1.5,-0.5,0.5,1.5\). For \(y\): \(-2.5,-0.5,0.5,2.5\).

The numerator is the sum of the four paired products:

$$ \sum (x_i-\bar{x})(y_i-\bar{y}) =3.75+0.25+0.25+3.75=8. $$

The sums of squared deviations are \(5\) for \(x\) and \(13\) for \(y\), so:

$$ r_{xy}=\frac{8}{\sqrt{5(13)}}=\frac{8}{\sqrt{65}}\approx 0.9923. $$

If the variables are reversed, the numerator is still \(3.75+0.25+0.25+3.75=8\), and the denominator is \(\sqrt{13(5)}=\sqrt{65}\). Thus \(r_{yx}\approx0.9923\) as well. In this hypothetical set, the two variables have a very strong positive linear association. The correlation calculation does not establish that practice sessions should be treated as the predictor or that the score should be treated as the response.

Symmetry Is About the Statistic, Not the Display

A scatterplot does require an axis choice: one variable is drawn horizontally and the other vertically. If the axes are switched, each point’s coordinates are reversed. The plot may look differently oriented on the page, but the set of paired observations has not changed, and neither has Pearson’s \(r\). In contrast, the labels and scales on the axes still matter for interpreting what the variables measure.

The same distinction applies to naming the variables. A question might use one variable to help describe or predict another, but that purpose comes from the investigation. Correlation alone has no built-in “first variable” or “second variable” with a special status. The formula treats the two columns symmetrically.

The following calculation shows that the symmetry holds for a negative association too. It is not a special feature of positive correlations.

Worked Example: Reversing the Order for a Negative Correlation

Consider hypothetical paired measurements for four individuals: \(x\) is age in years and \(y\) is a resting measurement in beats per minute. The pairs are \((20,72),(30,68),(40,64),(50,60)\). Find the correlation in both orders.

Both variables are quantitative, their values are paired by individual, and each varies. Their means are \(\bar{x}=35\) years and \(\bar{y}=66\) beats per minute. The deviations are \(-15,-5,5,15\) for \(x\), and \(6,2,-2,-6\) for \(y\).

The sum of paired products is:

$$ (-15)(6)+(-5)(2)+(5)(-2)+(15)(-6) =-90-10-10-90=-200. $$

The sums of squared deviations are \(500\) for \(x\) and \(80\) for \(y\). Therefore:

$$ r_{xy}=\frac{-200}{\sqrt{500(80)}} =\frac{-200}{200}=-1. $$

Reversing the order leaves the numerator at \(-200\) and the denominator at \(\sqrt{80(500)}=200\), so \(r_{yx}=-1\). The two orders give the same perfect negative linear correlation for these constructed observations. This arithmetic describes the paired values; it does not assign a direction of influence to the variables.

How to Report the Symmetry Clearly

When reporting a correlation, name both variables and their units or measurement scales, then describe the association without implying that one variable has been selected as the cause or outcome. For example, one can say, “In these hypothetical observations, practice sessions and task score have a strong positive linear association.” Swapping the names in that description does not change the correlation.

A correlation is unitless, even though the variables may have different units. This follows in part because deviations in each variable are scaled by that variable’s own spread. The symmetry discussed here is a separate fact: the same paired deviations appear in the numerator either way, while the same two spread terms appear in the denominator. Neither fact makes the correlation a directional effect.

Worked Example: Matching a Correlation Statement to the Data

Suppose a researcher records the number of pages and the word count, in thousands of words, for five hypothetical short articles. The paired values are \((1,8),(2,7),(3,9),(4,10),(5,11)\), where pages are \(x\) and thousands of words are \(y\). Calculate \(r\) and state what changes if the variables are listed in reverse order.

These are five paired observations; pages and word count are quantitative, and both vary. The means are \(\bar{x}=3\) pages and \(\bar{y}=9\) thousand words. The deviations are \(-2,-1,0,1,2\) for \(x\), and \(-1,-2,0,1,2\) for \(y\).

The sum of products is \(2+2+0+1+4=9\). The sum of squared deviations is \(10\) for each variable. Thus:

$$ r_{xy}=\frac{9}{\sqrt{10(10)}}=\frac{9}{10}=0.9000. $$

With word count listed first and pages second, the numerator is still \(9\), and the denominator is still \(\sqrt{10(10)}=10\). The correlation remains \(0.9000\). A suitable interpretation is that the hypothetical articles show a strong positive linear association between pages and word count. The value itself does not designate which variable is a predictor or response.

Common Mistake: Reading Direction Into the Correlation

Incorrect reasoning: “The correlation is calculated between pages and word count, so pages must be the predictor and word count must be the response.” That conclusion does not follow from the calculation. Reversing the two variables produces exactly the same correlation.

Correction: Treat \(r\) as a symmetric summary of the linear association in paired data. State which variable is a predictor or response only when the question or study design gives a reason to assign those roles. A scatterplot’s choice of horizontal and vertical axes may reflect that intended framing, but it does not make the numerical correlation directional.

This distinction matters because a symmetric statistic should not be used to claim that one variable explains, changes, or produces the other. Correlation describes an association; the number alone does not supply a direction of effect. Questions about causal interpretation require separate reasoning beyond this property of Pearson’s \(r\).

Key takeaway: For any paired quantitative data with variation in both variables, \(r_{xy}=r_{yx}\). Pearson’s correlation describes a linear association symmetrically; it does not, by itself, identify a predictor, a response, or a direction of effect.

Check Your Understanding

Try these questions without looking back.

  1. In the formula for \(r\), explain why switching \(x\) and \(y\) leaves the numerator unchanged.
  2. If \(r_{xy}=-0.62\), what is \(r_{yx}\)? Explain briefly.
  3. A scatterplot places study time on the horizontal axis and score on the vertical axis. Does that axis choice change the correlation if the axes are switched?
  4. What must be true of the observed values of each variable for the Pearson correlation formula to be defined?
  5. A report says that pages and word count have a positive correlation. Can that correlation alone identify which variable is a predictor? Why or why not?