MT LESSON 8
📚 MT-LESSON-8.pdf
Brief overview
This document details statistical methods for measuring the association between variables. Understanding correlation is essential for identifying relationships and making inferences in data analysis.
Key points
- Introduction to correlation coefficients and the characteristics of relationships.
- Spearman rank-order correlation and its application.
- Point biserial and phi coefficients for dichotomous variables.
- Utilizing scatterplots for visualization and assumption checking.
- Reporting correlation results in APA format.
1. Introduction to correlation
1.1 Correlation: measuring association
- Correlation: a statistical technique measuring the strength and direction of a linear association between two variables.
- It quantifies how strongly two variables are related.
- Variables are studied as they naturally exist, without manipulation.
- An example is examining the relationship between a student's grades and their economic status.
📝 Example: The relationship between daily allowance (X) and Grade Point Average (Y).
1.2 Types of correlation coefficients
Correlation coefficients vary based on the type of data scales used for the variables.
| Correlation Coefficient Type | Variable Scales |
|---|---|
| Pearson Product Moment | Both interval or ratio |
| Spearman Rank-Order | Both ordinal |
| Phi | Both naturally dichotomous |
| Point Biserial | One dichotomous, one interval or ratio |
1.3 Direction of relationships
The sign of the correlation coefficient indicates the direction of the relationship.
- Positive relationship: Both variables increase or decrease together. This is also known as direct correlation.
- Negative relationship: As one variable increases, the other decreases. This is also known as an inverse relationship.
📝 Example: As study hours increase (X), exam scores increase (Y) - positive. As hours spent on social media increase (X), exam scores decrease (Y) - negative.
1.4 Magnitude of correlation
Correlation coefficients range from +1 to -1.
- A coefficient of +1 indicates a perfect positive linear relationship.
- A coefficient of -1 indicates a perfect negative linear relationship.
- A coefficient of 0 indicates no linear relationship.
| Correlation Coefficient | Descriptive Meaning |
|---|---|
| Exactly +1 | Perfect uphill (positive) linear relationship |
| +0.70 to +0.99 | Strong uphill (positive) linear relationship |
| +0.50 to +0.69 | Moderate uphill (positive) linear relationship |
| +0.30 to +0.49 | Weak uphill (positive) linear relationship |
| 0 | No linear relationship |
| -0.30 to -0.49 | Weak downhill (negative) linear relationship |
| -0.50 to -0.69 | Moderate downhill (negative) linear relationship |
| -0.70 to -0.99 | Strong downhill (negative) linear relationship |
| Exactly -1 | Perfect downhill (negative) linear relationship |
🔑 Important: Values greater than 1 or less than -1 indicate a calculation error.
1.5 Pearson product-moment correlation (r)
- Pearson product-moment correlation (r): A common index for the relationship between two variables measured on interval or ratio scales.
- Its value ranges from +1 to -1.
The formula for Pearson's r is: r=[n∑x2−(∑x)2][n∑y2−(∑y)2]n∑xy−(∑x)(∑y)
Where:
- r = Pearson correlation coefficient
- n = sample size
- ∑xy = sum of the product of x and y
- (∑x)(∑y) = product of the sum of x and sum of y
- ∑x2 = sum of the squares of x
- ∑y2 = sum of the squares of y
1.5.1 Manual computation steps
- Count the number of observations (n).
- Calculate the sum of x (∑x).
- Square each x value (x2) and compute the sum of squares (∑x2).
- Calculate the sum of y (∑y).
- Square each y value (y2) and compute the sum of squares (∑y2).
- Calculate the product of x and y (xy) for each pair and compute the sum of products (∑xy).
- Apply the formula for r.
📝 Example: Calculating r for daily allowance (x) and GPA (y) yields r=0.90, indicating a strong positive linear relationship.
1.5.2 Pearson correlation in MS Excel
- Excel's
=PEARSON(array1, array2)function directly calculates the correlation coefficient. - To determine statistical significance, you can convert r to a t-statistic and then find the p-value.
The formula to convert r to a t-statistic is: t=1−r2rn−2
The p-value can be found using the =TDIST(x, deg_freedom, tails) function in Excel.
x: the calculated t-statistic.deg_freedom: degrees of freedom (n−2).tails: 1 for one-tailed, 2 for two-tailed analysis.
🔑 Important: Use the absolute value of r in the t-statistic formula if r is negative to avoid errors.
1.6 Pearson correlation in SPSS
SPSS provides a straightforward procedure for bivariate Pearson correlations.
1.6.1 Assumptions for Pearson correlation
- Interval or ratio variables: Both variables must be continuous.
- Linear relationship: A scatterplot should visually confirm a linear trend between variables.
- No significant outliers: Extreme data points can distort results. SPSS can help detect and manage outliers.
- Approximately normal distribution: Variables should be roughly normally distributed for statistical significance testing.
🔑 Important: Failure to meet these assumptions can invalidate correlation results. SPSS offers tools to test these assumptions, including Shapiro-Wilk tests for normality and boxplots for outliers.
1.6.2 Running a Pearson correlation in SPSS
- Navigate to
Analyze > Correlate > Bivariate. - Select the variables to be analyzed and move them to the
Variablesfield. - Ensure
Pearsonis selected underCorrelation Coefficients. - Choose
Two-tailedorOne-tailedfor the test of significance. - Optionally, check
Flag significant correlationsto mark significance levels in the output. - Click
Optionsto specify additional statistics or handle missing values (e.g., pairwise or listwise exclusion).
The output will include a Correlations table showing the correlation coefficient (r), p-value, and sample size (n) for each pair of variables.
🔑 Important: Always interpret the p-value in conjunction with the correlation coefficient (r) to understand both the statistical significance and the strength/direction of the relationship. 🔑 Important: Correlation indicates association, not causation. A significant correlation between two variables does not mean one causes the other.
2. Spearman rank-order correlation
2.1 Introduction to Spearman correlation
Spearman's rank-order correlation coefficient, denoted as rs, measures the strength and direction of association between two variables. It is a nonparametric test.
-
Use cases:
- Ordinal variables.
- Continuous data that fails Pearson correlation assumptions.
-
Formula: rs=1−n(n2−1)6∑D2
- rs: The correlation coefficient.
- ∑D2: Sum of squared differences between ranks of x and y.
- n: Number of observations.
2.2 Computing Spearman's rho by hand
Calculating Spearman's rho involves ranking data and then applying the formula.
- Steps:
- Rank data for the first variable (x) from highest to lowest.
- Rank data for the second variable (y) from highest to lowest.
- Compute the difference (D) between the ranks for each pair.
- Square each difference (D2).
- Sum the squared differences (∑D2).
- Determine the number of observations (n).
- Apply the Spearman correlation formula.
Example Calculation: For 10 students, ranks for English (x) and Maths (y) showed ∑D2=88.
rs=1−10(102−1)6×88=1−990528=1−0.53=0.47 This indicates a weak positive linear relationship.
2.3 Spearman correlation in Excel
Excel does not have a direct function for Spearman's rho. However, you can compute it using existing functions.
- Procedure:
- Rank Data: Use the
RANK.AVGfunction for each variable to assign ranks. For example, to rank data in cell B2 within the range B2:B11 with no ties broken:=RANK.AVG(B2,$B$2:$B$11,0). Ensure you use absolute cell references (USD) for the range. - Calculate Correlation: Use the
CORRELfunction on the ranked data. For instance, if ranks for variable 1 are in D2:D11 and for variable 2 in E2:E11, use=CORREL(D2:D11, E2:E11).
- Rank Data: Use the
Example Result: Using physical activity and blood pressure data, Excel's
CORRELfunction on ranks yielded -0.7576. This suggests a strong negative correlation.
2.4 Assumptions for Spearman correlation
For valid results, Spearman's correlation requires data to meet specific assumptions.
-
Variable Measurement:
- Variables should be ordinal, interval, or ratio scale.
- Examples: Likert scales (ordinal), revision time in hours (interval/ratio).
-
Paired Observations:
- Data must consist of paired observations.
- Each pair represents scores for the same participant on both variables.
-
Monotonic Relationship:
- A monotonic relationship exists when variables consistently increase or decrease together.
- Visually check this using a scatterplot in software like SPSS.
Important: Monotonicity is key. While Spearman's correlation measures the degree of this relationship, if the relationship is clearly not monotonic, other statistical measures might be more appropriate.
2.5 Spearman correlation in SPSS
SPSS provides a straightforward way to compute Spearman's rank-order correlation.
-
Procedure:
- Navigate to
Analyze > Correlate > Bivariate...in the SPSS menu. - Transfer the two variables of interest into the
Variables:box. - In the
Correlation Coefficientsarea, uncheckPearsonand checkSpearman. - Click
OKto generate the output.
- Navigate to
-
Output Interpretation:
- SPSS provides a correlation matrix showing Spearman's rho (rs), its significance value (p-value), and the sample size (n).
- A statistically significant correlation (typically p<0.05) suggests a genuine association.
Example Reporting: A Spearman's correlation analysis revealed a strong, positive, and statistically significant correlation between English and maths marks (rs=0.669,p=0.035) 8.
Important: Spearman's correlation is robust to non-normally distributed data and is less sensitive to outliers compared to Pearson's correlation.
3. Point biserial and phi coefficient
3.1 Point biserial correlation coefficient
The point biserial correlation coefficient (rpbi) measures the relationship between a continuous variable and a dichotomous variable. It ranges from -1 to +1, similar to Pearson's r.
To calculate rpbi, the dichotomous variable is coded numerically, typically as 0 and 1. The standard Pearson correlation formula is then used.
The interpretation of rpbi is similar to Pearson's r.
The formula for the point biserial correlation coefficient is: rpbi=[n∑x2−(∑x)2][n∑y2−(∑y)2]n∑xy−(∑x)(∑y)
Where:
- n is the sample size.
- ∑xy is the sum of the products of the two variables.
- ∑x and ∑y are the sums of each variable.
- ∑x2 and ∑y2 are the sums of the squared values of each variable.
3.1.1 Example calculation
Consider data on gender (0=female, 1=male) and IQ score:
| Participant | Gender (x) | IQ (y) | x2 | y2 | xy |
|---|---|---|---|---|---|
| A | 1 | 86 | 1 | 7396 | 86 |
| B | 1 | 87 | 1 | 7569 | 87 |
| C | 1 | 91 | 1 | 8281 | 91 |
| D | 1 | 97 | 1 | 9409 | 97 |
| E | 1 | 98 | 1 | 9604 | 98 |
| F | 1 | 99 | 1 | 9801 | 99 |
| G | 0 | 85 | 0 | 7225 | 0 |
| H | 0 | 79 | 0 | 6241 | 0 |
| I | 0 | 83 | 0 | 6889 | 0 |
| J | 0 | 86 | 0 | 7396 | 0 |
| K | 0 | 81 | 0 | 6561 | 0 |
| L | 0 | 92 | 0 | 8484 | 0 |
- n=12
- ∑x=6
- ∑y=1064
- ∑x2=6
- ∑y2=94836
- ∑xy=558
rpbi=[12−2][12−2]12− . rpbi=[72−36][1138032−1132096]6696−6384 rpbi=312=462.27312≈0.67 36 .
A computed value of 0.67 suggests a moderate positive relationship between IQ and gender 33.
3.1.2 Using statistical software
- Excel: The
=CORREL()function can be used directly on the numerically coded dichotomous variable and the continuous variable 34. - SPSS: The point biserial correlation is a special case of the Pearson's product-moment correlation, calculated via the "Correlate > Bivariate" menu. 39-41
3.1.3 Assumptions for point biserial correlation
For a valid result, the following assumptions should be met:
| Assumption # | Requirement | Example |
|---|---|---|
| 1 | One variable is continuous. | Revision time (hours), IQ score. |
| 2 | The other variable is dichotomous. | Gender (male/female), smoker (yes/no). |
| 3 | No outliers in the continuous variable for each group. | Use boxplots to check for outliers in males and females separately. |
| 4 | Continuous variable is approximately normally distributed. | Check using Shapiro-Wilk test, skewness/kurtosis, histograms, or Q-Q plots. |
| 5 | Continuous variable has equal variances for each group. | Test using Levene's test of equality of variances. |
If assumptions #3, #4, or #5 are violated, the interpretation of the point-biserial correlation may not be valid. 36-38
3.2 Phi coefficient
The phi coefficient (ϕ) measures the association between two binary (dichotomous) variables. It is used when both variables are nominal and have only two categories.
Data is typically presented in a 2×2 contingency table.
3.2.1 Interpretation of Phi coefficient
The interpretation of the phi coefficient is similar to Pearson's r:
| Range | Association |
|---|---|
| -1.0 to -0.7 | Strong negative association |
| -0.7 to -0.3 | Weak negative association |
| -0.3 to +0.3 | Little or no association |
| +0.3 to +0.7 | Weak positive association |
| +0.7 to +1.0 | Strong positive association |
3.2.2 Formula and calculation
The formula for the phi coefficient is: ϕ=efghad−bc
Where the contingency table is coded as:
| Variable Y=0 | Variable Y=1 | Total | |
|---|---|---|---|
| Variable X=1 | A | C | E |
| Variable X=0 | B | D | F |
| Total | G | H | N |
- a,b,c,d are the frequencies in the 2×2 table cells.
- e,f,g,h are the row and column totals used in the denominator.
Example 1: Gender and Position
| Position/Gender | Female | Male | Total |
|---|---|---|---|
| Staff | 20 (A) | 12 (C) | 32 (E) |
| Faculty | 13 (B) | 18 (D) | 31 (F) |
| Total | 33 (G) | 30 (H) | 63 (N) |
Here, a=20,b=13,c=12,d=18. e=32,f=31,g=33,h=30.
ϕ=32×31×33×30(20×18)−(12×13) ϕ=982080360−156=990.99204≈0.21 This indicates little or no association. 42-43
Example 2: Age and Position
| Position/Age | Adult | Adolescent | Total |
|---|---|---|---|
| Student | 30 (A) | 45 (B) | 75 (E) |
| Faculty 1 | 22 (C) | 38 (D) | 60 (F) |
| Total | 52 (G) | 83 (H) | 135 (N) |
Here, a=30,b=45,c=22,d=38. e=75,f=60,g=52,h=83.
ϕ=75×60×52×83(30×38)−(45×22) ϕ=19,422,0001140−990=4,407.04150≈0.03 This also indicates little or no association. 43-44
The phi coefficient is for two binary variables, while the point biserial coefficient is for one binary and one continuous variable.
🔑 Important: Both point biserial and phi coefficients help understand the strength and direction of relationships between variables, with specific use cases depending on the measurement scales of the variables involved 44.
4. Scatterplots and reporting correlations
4.1 Creating scatterplots in SPSS
A scatterplot is useful for several reasons. It helps determine if a relationship between two variables is linear.
It also allows for the detection of outliers. Finally, it visually presents the relationship between two continuous variables.
This is important for assumptions in statistical tests like Pearson correlation and linear regression 45.
To create a scatterplot in SPSS Statistics:
- Navigate to Graphs > Chart Builder....
- In the Choose from: box, select "Scatter/Dot".
- Drag the "Simple Scatter" option into the chart preview pane.
- Drag your independent variable to the "X-Axis?" box and your dependent variable to the "Y-Axis?" box 47.
🔑 Important: The chart preview in the Chart Builder does not show your actual data. The true plot appears only after generating the scatterplot 48.
You can adjust the scale of the axes in the Element Properties dialogue box. For example, you can set a minimum value for the Y-axis to ensure a suitable range of values is displayed for your data 49 50.
4.2 Reporting correlation results
When reporting correlations, especially in APA format, a table is standard. This table should include key statistics about the variables and the correlation itself.
Here's a breakdown of how to report Pearson correlation results:
- M: Mean of the variable.
- SD: Standard deviation of the variable.
- r: The Pearson correlation coefficient. This indicates the strength and direction of the linear relationship.
- p: The p-value, indicating statistical significance.
- Decision: The statistical decision regarding the null hypothesis (e.g., Reject H₀).
📝 Example: A correlation coefficient (r) of.789 suggests a moderate to strong positive association. A p-value of.001 (p <.001) indicates that this relationship is statistically significant at the 0.05 level (2-tailed).
🔑 Important: Always interpret the direction and strength of the correlation in the context of your research question, and clearly state the significance level 51.
© 2026 Maeve. All rights reserved. This content is protected by copyright.