An assumption of the independent samples t-test is that the outcome variable is normally distributed for each group. The distribution of the data can be visually checked using a Q-Q plot and/or a histogram.
Information about testing normality in the video “Testing normality” at the ufora website.
The Q–Q (quantile-quantile) plot is a probability plot, which is a graphical method for comparing two probability distributions by plotting their quantiles against each other.
Here we have a Q-Q plot for normality where we plot our data versus the corresponding quantiles of the standard normal distribution.
When data are normally distributed, they follow more or less the straight line.
par(mfrow=c(1,2))
qqnorm(BEPAS$MVPA_acc [BEPAS$Walkability=="Low walkability"])
qqline(BEPAS$MVPA_acc [BEPAS$Walkability=="Low walkability"])
qqnorm(BEPAS$MVPA_acc [BEPAS$Walkability=="High walkability"])
qqline(BEPAS$MVPA_acc [BEPAS$Walkability=="High walkability"])