Pearson’s r is one of the most widely used tools in psychological research – it tells you how strongly two variables are related and in which direction. But knowing what it measures is only half the equation. The other half is knowing how to calculate it efficiently. The raw score method gives you a direct, structured path to computing r without the extra step of converting all your data into deviation scores first. This tutorial walks you through the formula, its components, and a complete worked example so you can apply it confidently to your own data.

Table of Contents

What is Pearson’s r and why does the calculation method matter?

Pearson’s correlation coefficient is a numerical measure of the linear relationship between two continuous variables. Its value always falls between โˆ’1 and +1. A value near +1 signals a strong positive relationship (both variables increase together), a value near โˆ’1 signals a strong negative relationship (one rises as the other falls), and a value near 0 means little to no linear association. Developed by Karl Pearson around 1900, the coefficient has since become a cornerstone of statistical analysis in psychology, education, and the social sciences.

There are at least three established formulas for computing r: the raw score formula, the deviation score formula, and the covariance formula. Critically, all three produce exactly the same result. The choice of method is purely a matter of convenience and the form in which your data is available. The raw score method is particularly useful when you are working directly with original data points and want to avoid computing means and deviations for every individual score before you can even begin the correlation calculation.

Understanding the raw score formula

The raw score formula for Pearson’s r is:

r = [Nโˆ‘XY โˆ’ (โˆ‘X)(โˆ‘Y)] / โˆš[(Nโˆ‘Xยฒ โˆ’ (โˆ‘X)ยฒ)(Nโˆ‘Yยฒ โˆ’ (โˆ‘Y)ยฒ)]

At first glance, this looks intimidating. But each component has a clear, specific role. Here is what every symbol means:

  • N – the total number of paired data points (e.g., if you have 8 participants, N = 8)
  • โˆ‘X and โˆ‘Y – the simple sums of all values in variable X and variable Y respectively
  • โˆ‘XY – the sum of the products of each paired X and Y value (multiply each X by its corresponding Y, then add all those products)
  • โˆ‘Xยฒ and โˆ‘Yยฒ – the sum of the squared values of X and Y (square each individual value first, then sum them)
  • (โˆ‘X)ยฒ and (โˆ‘Y)ยฒ – the squares of the sums (sum all values first, then square the total)

That last distinction – between โˆ‘Xยฒ and (โˆ‘X)ยฒ – is one of the most common sources of error among students. โˆ‘Xยฒ means: square each score, then add. (โˆ‘X)ยฒ means: add all scores first, then square the total. These produce very different numbers. Getting this right is essential to an accurate result.

The deviation score method: a quick comparison

To appreciate why the raw score method is useful, it helps to briefly understand what the deviation score method requires. The deviation score approach is built around the concept of the sum of products – a measure of the variability shared between two variables. It requires you to first calculate the mean of X and the mean of Y, then subtract each individual score from its respective mean to produce deviation scores, and only then compute cross-products and sums of squares.

The raw score method bypasses those intermediate steps entirely. Raw score formulas are algebraic transformations of the z-score approach, rearranged so you can work with original values directly. The result is fewer calculation steps, fewer rounding errors from intermediate arithmetic, and a more streamlined process – especially with smaller datasets using whole numbers. Both methods yield identical values for r. This equivalence is not a coincidence; it is a mathematical identity built into the formula’s structure.

Step-by-step example: hours of sleep and reaction time

Let’s say a researcher wants to know whether hours of sleep the night before an experiment is related to reaction time (in milliseconds) in a cognitive test. Data is collected from 6 participants. Assign sleep hours as X and reaction time as Y.

Here is the dataset:

  • Participant 1: X = 5, Y = 310
  • Participant 2: X = 6, Y = 290
  • Participant 3: X = 7, Y = 275
  • Participant 4: X = 8, Y = 250
  • Participant 5: X = 9, Y = 240
  • Participant 6: X = 4, Y = 330

Step 1: Set up your calculation table

Create columns for X, Y, XY, Xยฒ, and Yยฒ. This is the standard approach recommended for the raw score method, as it keeps every required value organised in one place before you apply the formula.

  • Participant 1: XY = 1550, Xยฒ = 25, Yยฒ = 96100
  • Participant 2: XY = 1740, Xยฒ = 36, Yยฒ = 84100
  • Participant 3: XY = 1925, Xยฒ = 49, Yยฒ = 75625
  • Participant 4: XY = 2000, Xยฒ = 64, Yยฒ = 62500
  • Participant 5: XY = 2160, Xยฒ = 81, Yยฒ = 57600
  • Participant 6: XY = 1320, Xยฒ = 16, Yยฒ = 108900

Step 2: Calculate the column sums

Sum each column to get the values you will plug into the formula:

  • โˆ‘X = 5 + 6 + 7 + 8 + 9 + 4 = 39
  • โˆ‘Y = 310 + 290 + 275 + 250 + 240 + 330 = 1695
  • โˆ‘XY = 1550 + 1740 + 1925 + 2000 + 2160 + 1320 = 10695
  • โˆ‘Xยฒ = 25 + 36 + 49 + 64 + 81 + 16 = 271
  • โˆ‘Yยฒ = 96100 + 84100 + 75625 + 62500 + 57600 + 108900 = 484825
  • N = 6

Step 3: Compute the squared sums

Now compute (โˆ‘X)ยฒ and (โˆ‘Y)ยฒ – the squares of the totals you just found:

  • (โˆ‘X)ยฒ = 39ยฒ = 1521
  • (โˆ‘Y)ยฒ = 1695ยฒ = 2,873,025

Step 4: Plug values into the formula

Now substitute everything into the raw score formula:

Numerator: Nโˆ‘XY โˆ’ (โˆ‘X)(โˆ‘Y) = (6 ร— 10695) โˆ’ (39 ร— 1695) = 64170 โˆ’ 66105 = โˆ’1935

Denominator (X part): Nโˆ‘Xยฒ โˆ’ (โˆ‘X)ยฒ = (6 ร— 271) โˆ’ 1521 = 1626 โˆ’ 1521 = 105

Denominator (Y part): Nโˆ‘Yยฒ โˆ’ (โˆ‘Y)ยฒ = (6 ร— 484825) โˆ’ 2873025 = 2908950 โˆ’ 2873025 = 35925

Full denominator: โˆš(105 ร— 35925) = โˆš(3772125) โ‰ˆ 1942.2

r = โˆ’1935 / 1942.2 โ‰ˆ โˆ’0.996

Step 5: Interpret the result

An r of approximately โˆ’0.996 indicates a very strong negative correlation. As hours of sleep increase, reaction time decreases – meaning better-rested participants responded faster. The closer r is to โˆ’1 or +1, the stronger the linear relationship between the two variables. In this case, sleep duration is an excellent predictor of reaction time in this sample.

It is critical to note, however, that a high correlation does not prove causation. Other variables – such as caffeine intake, stress levels, or time of day – could also be contributing to reaction time differences. Correlation tells you that two variables are related; it does not tell you why.

Common mistakes to avoid

A few errors come up repeatedly when students first apply the raw score formula. Being aware of them in advance saves a great deal of recalculation.

When to choose the raw score method

The raw score method is best suited to situations where you have a manageable dataset – typically fewer than 30 pairs – and want a direct, step-by-step path from original data to r. It is especially valuable in educational settings where showing and understanding each calculation step matters. Because it works with data exactly as collected, it eliminates the rounding errors that can accumulate when you first convert to deviation scores and then compute further.

For larger datasets, statistical software handles the arithmetic automatically, but the underlying computation follows the same principles. The raw score formula is an algebraic rearrangement of the z-score-based definition of correlation, which means the method is not a shortcut or approximation – it is mathematically equivalent to every other valid approach. Understanding it deeply gives you insight into what Pearson’s r is actually measuring: the degree to which variation in one variable tracks variation in another, expressed on a standardised scale from โˆ’1 to +1.

What do you think? If you were designing a psychological study to examine the relationship between screen time and sleep quality in adolescents, which variables would you designate as X and Y – and what r value would you predict finding? Does it change how you interpret the result when you know that both the raw score and deviation score methods are guaranteed to produce the same r?

How useful was this post?

Click on a star to rate it!

Average rating 4.5 / 5. Vote count: 2

No votes so far! Be the first to rate this post.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?

References
  1. https://en.wikipedia.org/wiki/Pearson_correlation_coefficient
  2. https://www.sciencedirect.com/topics/computer-science/pearson-correlation
  3. https://www.andrews.edu/~calkins/math/edrm611/edrm05.htm
  4. https://open.maricopa.edu/psy230mm/chapter/chapter-16-correlations/
  5. https://lbecker.uccs.edu/ancova2
  6. https://www.socscistatistics.com/tests/pearson/
  7. https://www.cogn-iq.org/learn/theory/pearson-correlation/

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Statistics in Psychology

1 Introduction to Statistics

  1. Meaning of Statistics
  2. Types of Statistics
  3. Scope and Use of Statistics
  4. Limitations of Statistics
  5. Distrust and Misuse of Statistics

2 Descriptive Statistics

  1. Organising Data
  2. Summarising Data
  3. Use of Descriptive Statistics

3 Inferential Statistics

  1. Concept and Meaning of Inferential Statistics
  2. Inferential Procedures
  3. Hypothesis Testing
  4. General Procedure for Testing Hypothesis

4 Frequency Distribution and Graphical Presentation

  1. Arrangement of Data
  2. Tabulation of Data
  3. Graphical Presentation of Data
  4. Diagrammatic Presentation of Data

5 Concept of Central Tendency

  1. Meaning of Measures of Central Tendency
  2. Functions of Measures of Central Tendency
  3. Types of Measures of Central Tendency
  4. Characteristics of a Good Measures of Central Tendency

6 Mean, Median and Mode

  1. Symbols Used in Calculation of Measures of Central Tendency
  2. The Arithmetic Mean
  3. The Median
  4. The Mode
  5. When to Use the Various Measures of Central Tendency

7 Concept of Dispersion

  1. Concept of Dispersion
  2. Functions of Dispersion
  3. Measures of Dispersion
  4. Significance of Measures of Dispersion
  5. Types of Measures of Variability/Dispersion

8 Range, MD, SD and QD

  1. Range
  2. Quartile Deviation
  3. The Average Deviation
  4. The Standard Deviation
  5. When to Use Different Measures of Dispersion

9 Introduction to Parametric Correlation

  1. Introduction to Correlation
  2. Scatter Diagram
  3. Correlation: Linear and Non-Linear Relationship
  4. Direction of Correlation: Positive and Negative
  5. Correlation: The Strength of Relationship
  6. Measurements of Correlation
  7. Correlation and Causality
  8. Uses of Correlation

10 Product Moment Coefficient of Correlation

  1. Building Blocks of Correlation
  2. Pearsonโ€™s Product Moment Coefficient of Correlation
  3. Interpretation of Correlation
  4. Using Raw Score Method for Calculating r
  5. Significance Testing of r
  6. Other Types of Pearsonโ€™s Correlation

11 Introduction to Non-Parametric Correlation

  1. Parameter Estimation
  2. Parametric and Non-parametric Statistics
  3. Scales of Measurement
  4. Conditions for Rank Order Correlations
  5. Ranking of the Data
  6. Rank Correlations

12 Rank Correlation (rho and Kendall Rank Correlation

  1. Rank-Order Correlations
  2. Spearmanโ€™s rho (rs)
  3. Kendallโ€™s tau (ฯ„)

13 Significance of the Difference of Frequency- Chi-Square

  1. Parametric and Non-Parametric Statistics Tests
  2. Chi-square Test: Definitions
  3. Assumptions for the Application of x2 Test
  4. Properties of the Chi-square Distribution
  5. Application of Chi-square Test
  6. Precautions about Using the Chi-square Test

14 Concept and Calculation of Chi-Square

  1. Application of Chi-square Test
  2. The Chi-square Test when Table Entries are Small (Yateโ€™s Correction)
  3. Chi-square as a Test of Independence
  4. 2 ร— 2 Fold Contingency Tables

15 Significance of the Differences between Means (T-value)

  1. Need and Importance of the Significance of the Difference between Means
  2. Fundamental Concepts in Determining the Significance of the Difference between Means
  3. Methods to Test the Significance of Difference between the Means of Two Independent Groups (t-test)
  4. Significance of the Difference Between two Correlated Means

16 Normal Distribution- Definition, Characteristics and Properties

  1. Definitions of Probability
  2. The Normal Distribution
  3. Deviation from the Normality
  4. Characteristics of a Normal Curve
  5. Properties of the Normal Distribution
  6. Application of the Normal Curve