Research has shown that exercise have very positive effects on human health. One specific area that exercise has been correlated to is memory. Studies have shown that acute exercise in preadolescences and adults led to improved memory (Pesce et al., 2009, Roig et al., 2013). This study looks to expand upon the kind of exercise that improves memory on the Islands. Instead of specifically requiring that participants do acute exercise, islanders were separated into groups based on whether they exercised at all or not. They were asked to complete a timed memory game to asses their memory. It is expected that the Islanders who exercise will have a higher overall mean than islanders who do not exercise.

The observational units of this study are the 49 islanders aged 19-112 who were approximately selected at random. To select the islanders, I went through each town one by one. Once I selected a town, I closed my eyes and scrolled through the towns with my eyes closed until I selected a house. The first person who’s name I saw was the person to participate in the study. If that person was not over 18 or declined to participate, then I would go back to the same town and randomly select a house again using the same process. Once the participant consented, I asked them “Do you exercise?” using the questionnaire feature. I recorded whether they said yes or no. I then asked them to complete the memory game. I would then go through the same process in the next town until I reached 49 participants. The memory game presented the islanders with 30 face-down cards and the islanders had to match each one as quickly as they could. Their time was recorded as a measure of their memory skills. This study was relatively easy to collect data for since it only rquired two visits to the islanders: one to have them begin the study and another to record their data. Once I reached 49 subjects, I went through all my contacts and recorded whether they exercised or not and their memory game time. The loss of islanders, either from passing away or dropping out, did not have any affect on the data or collection since I did not need to test them more than once.

The variables in this study consisted of a categorical and a quantitative variable. The binary categorical variable was the explanatory variable and the options for the variable were that the islander either exercised or did not exercise. The response variable was quantitative and was the islanders memory game time in seconds.

library(readr)
ExMem_Data <- read_csv("~/MATH 247 Spring 2024/Mini Projects/FinalDataCollection - Sheet1.csv")
head(ExMem_Data, n=2)
bwplot(exercise ~ time, 
       horizontal = TRUE, 
       main="Side-by-side boxplots",
       data = ExMem_Data)

The side-by-side boxplots of the exercise and no exercise groups seem to be relatively similar. The boxes overlap in the center which does not provide great evidence of an association between exercise and memory game time. The medians also look to be relatively similar, within about 10 seconds, but I will explore this further in the summary statistics below.

data(ExMem_Data)
favstats(time ~ exercise, data = ExMem_Data)

The summary statistics shown in the table above give a lot of information about the association. The two explanatory variables have very similar mean times, within 2 seconds, which does not provide very good initial evidence of an association. The standard deviations are very high, but it is a good thing that they are similar because it means one group was not more varied than the other. The similar standard deviations are rather surprising given the whiskers in the box plots, but given the range of the Q1-Q3 values in the no exercise group, with smaller whiskers, it makes sense that the standard deviations are similar. The exercise group does seem to have a smaller minimum and maximum, which is promising given that I expect the exercise group to have shorter times than the no exercise group. Based on all these things, there may be a small association between memory game score and exercise habits, but I do not have much evidence.

The 49 islanders between the ages of 19-112 were the subjects of this study which tests whether there is an association between exercise and memory. Specifically, the study tests the memory game score of the islanders to try to determine a population mean memory game score for the exercise and the no exercise group. The parameter of interest is the difference in these two means. The null hypothesis is that there will not be a difference in the mean memory game times of islanders who do not exercise and islanders who do exercise. This null hypothesis can be represented by the expression \(H_o\): \(\mu_{no \ \ exercise}\) - \(\mu_{exercise}\) = 0. The alternative hypothesis is that there is a difference in mean memory game times between the no exercise group and the exercise group and the exercise group will have a lower average time. This alternative hypothesis can be represented by the expression \(H_A\): \(\mu_{no \ \ exercise}\) - \(\mu_{exercise}\) > 0. In this setting, a type I error would be if I rejected the null hypothesis, but there actually was no difference in the mean memory game times of each group. A type II error would occur if I failed to reject the null hypothesis when there actually was a difference in the mean memory game times of the two groups. These errors will hopefully not happen because this is a representative sample of the Islanders. Since I picked an approximately random sample of Islanders where there was an equal amount coming from each island, this should be representative of the population of 19-112 year olds on the Islands.

The next step is to analyze the data that the study collected. To do this I will find the value of the sample statistic. Next, I will use the theory-based approach to find the t-statistic and one-sided p-value.

diff(rev(mean(time~exercise, data = ExMem_Data)))
##       no 
## 1.729483

The no exercise group takes 1.73 seconds longer to complete the memory game on average.

stat(t.test(time ~ exercise, data = ExMem_Data))
##         t 
## 0.4409062

The value of the theory-based t-statistic is 0.44.

two.sided.p.value<-pval(t.test(time ~ exercise, data = ExMem_Data))
cat("the one-sided p-value for the theory-based approach is",two.sided.p.value/2)
## the one-sided p-value for the theory-based approach is 0.3307574

This p-value of 0.33 means that there is little evidence against the null hypothesis. Therefore, based on the theory-based approach, I will fail to reject the null hypothesis. However, this is not my final conclusion of this analysis since the data does not follow the necessary validity conditions of the theory-based approach. Although there are at least 20 observations in each explanatory variable group, the distribution is not symmetrical and I cannot confirm that it is not skewed based on the distribution below.

histogram(~time | exercise, data = ExMem_Data, width = 1, layout = c(1, 2))

Out of an abundance of caution, I will also analyze this data using the simulation-based approach to confirm my conclusion above. I will again obtain a p-value using this approach.

set.rseed(498) 
Ex.null <- do(1000) * diffmean(shuffle(time) ~ exercise, data = ExMem_Data)
head(Ex.null,2)
dotPlot(~ diffmean,
        data = Ex.null,
        main="Simulated null distribution of the difference in sample means",
        xlab="difference in sample means",
        width = 2, cex = 1,
        groups = (diffmean >= 1.729483))

p_value<-prop(~(diffmean >= 1.729483), data = Ex.null)
cat("right-tailed p-value for the simulation-based approach is", p_value)
## right-tailed p-value for the simulation-based approach is 0.328

This p-value of 0.33 obtained from the simulation-based approach is approximately the same as the p-value that was obtained using the theory-based approach. Again, the conclusion of this analysis is that I fail to reject the null hypothesis which means there is not a significant difference between the mean memory game scores of the no exercise and exercise groups.

Next, I will find both the theory-based and simulation-based 95% confidence intervals to confirm this conclusion. I did both just to be sure of an accurate confidence interval since I am not positive that the data satisfies the validity conditions of the theory-based approach.

confint(t.test(time ~ exercise, data = ExMem_Data))

The theory-based 95% confidence interval is from -6.2 to 9.6.

x.bar.diff <- 1.729483

# simulated standard deviation
SE.x.bar.diff <- sd(~ diffmean, data = Ex.null)

# margin of error for 95% CI
MoE <- 2 * SE.x.bar.diff

LB<-x.bar.diff - MoE # lower limit of 95% CI
UB<-x.bar.diff + MoE # upper limit of 95% CI
round(cbind(LB,UB),3)
##          LB    UB
## [1,] -6.054 9.513

The simulation-based confidence interval is -6.1 to 9.5.

These confidence intervals are very similar which means that both approaches are a good form of analysis for this data. The 95% confidence interval of the the mean difference in memory game times for the no exercise and exercise group for the Islanders population is between about -6 and 9. The inclusion of zero in this interval provides more evidence in supoort of the null hypothesis since it is likley that the populations difference in meams may be equal to zero, as the null hypothesis states. This is the same conclusion that was reached using the theory-based and simulation-based p-values.

This study explored a potential relationship between exercise and memory in 49 adults (ages 19-112) in the islands. The memory game was used to quantify the memory of the islanders to a time value in seconds. The goal of the study was to find the difference in the population mean memory game time of islanders who didn’t exercise and islanders who did exercise. Both the theory-based and simulation-based approaches were used to analyze this data since the validity conditions did not appear to be satisfied. The two approaches identified very similar p-values of 0.3 which did not provide any evidence against the null hypothesis. The 95% confidence intervals of the population parameter of both approaches was about -6 to 9 which includes zero. This also does not provide evidence against the null hypothesis since zero is a possible value for the difference in means. Ultimately, the p-values and 95% confidence intervals provided evidence in support of the null hypothesis that there is no difference in the mean memory game times for Islanders who do not exercise and islanders who do exercise. This was not the result I was expecting given the studies that I read prior to this project. I expected that the exercise group would have a lower average memory game time. It is reasonable to generalize this study to all adult islanders between the ages 19-112 because the study employed random selection of participants who were sampled from every town in the Islands. The only aspects of this study that I would change would be to increase my sample size so the uncertainty, or standard deviation, would decrease. Other research projects could investigate whether the islanders behaved similarly to the studies cited. They would study whether acute exercise had an affect on memory. Another question that could be studied is whether the type of exercise the islanders did affected their memory. Both of these options would be experimental studies which means the researchers could draw cause-and-effect conclusions from these studies. Even if there was an association between the variables in this study, I could not draw a cause-and-effect relationship between the variables because this was an observational study.

Bibliography

Pesce, Caterina, et al. “Physical activity and mental performance in preadolescents: Effects of acute exercise on free-recall memory.” Mental Health and Physical Activity, vol. 2, no. 1, June 2009, pp. 16–22, https://doi.org/10.1016/j.mhpa.2009.02.001.

Roig, Marc, et al. “The effects of cardiovascular exercise on human memory: A review with meta-analysis.” Neuroscience & Biobehavioral Reviews, vol. 37, no. 8, Sept. 2013, pp. 1645–1666, https://doi.org/10.1016/j.neubiorev.2013.06.012.