Introduction

The research question I was focused on answering was: do rainy days impact mood? In order to answer this question, I had to determine the difference between the long run proportion of the population of islanders that were happy when there was high amounts of rain \((π_{highRain})\) vs when there was low amounts of rain \((π_{lowRain})\). I was interested in this question since I’m from Western Washington, which is stereotyped by long, rainy, falls, springs, and winters. Seasonal Affective Disorder is very real, and depressive symptoms have been found to occur in some individuals in association with long stretches of certain seasonal weather patterns (Mayo Clinic). This is most experienced in the fall and winter, but some have been known to experience symptoms in the spring and summer instead. I was curious about the role of rain specifically, and since seasons was outside of the scope of this project time-wise, I felt it would be a better option to monitor. More colloquially, people talk about seasonal depression, and the impact of weather on mood. From anecdotal experience I’ve heard complaints about cloudy or rainy weather impacting mood. A study on seasonal and meteorological associations with depressive symptoms in older adults concluded that rainfall did have an association with greater depressive symptoms, finding “a higher level of rain fall within the prior and/or current calendar month was associated with a greater number of depressive symptoms at the time of interview in this cohort” (O’Hare). However, another article about seasonality and the effects of weather on mood found “the prevalence of major depression and sad mood showed seasonal variation, with peaks in the summer and fall. Weather conditions were not associated with mood, and did not explain the seasonal variation we found.”We conclude that, contrary to popular belief, weather conditions and sad mood or depression do not seem to be associated.” (Huibers, 2010)

Due to these conflicting views, I wanted to replicate the weather component of this study focusing on rain to come to my own conclusions. Before looking at the data, I had no idea whether the actual parameter would be higher or lower, but I did assume it would be different.

Data Collection Methods

The observational units for this study were islanders. Data was collected on a randomly selected group of islanders. 29 from Ironbard, 29 from Bonne Sante, and 28 from Providence island. All told, 86 islanders from the the Islanders virtual website were assessed about their mood over the course of a day. To start, a random number generator (from the bing homepage) was used to select houses in Hofn, Ironbard, Maeva, Bonne Santa, and Biruwa, Providence. If multiple people were in a house, I assigned each person (older than 5) a number and then ran another random generator. If the house was unoccupied, I skipped that house and re-ran the number generator. If people declined to be in my survey I skipped them and re-ran the random number generator to get a new house entirely. This happened ten times. Once I had my participants, I asked them “what is your mood today?” which I documented as their exact response. To double check, I looked at the mood graphics displayed by the islander (smiling = happy, frown = sad) I tried to ask their mood at ~ 7:00 pm to give enough time for weather to influence their mood, but also allow me to collect my data before they fell asleep. This wasn’t a perfect system since its possible rainfall happened later in the night (and mood would therefore not be affected). Unfortunately, the Islands doesn’t collect data on time of rainfall. I would have rather asked my question even later in the evening, however the islanders tended to go to sleep anywhere from 9 to 10 pm. I wanted to make sure to collect enough data that both low rain high rain were represented so I chose to monitor people from all three islands because I wanted to make sure that I could find different levels of rainfall. I collected rainfall in mm from the closest climate stations to Hofn (Abramsen Climate Station), Maeva (Konah Climate Station), and Biruwa (Kennedy Climate Station). Once collected, the rainfall data was organized into quantitative categories: low (below 1 mm of rainfall) and high (above 1 mm of rainfall). None of the data was exactly 1 mm, so it wasn’t an issue whether to count it as low or high. I would have preferred there to be higher rainfall levels, but since this is an observational study I couldn’t dictate the amount of rain. Due to collection time constraints, I had to collect in summer, which may have also reduced total rainfall.

Descriptive Statistics

I looked at two variables for this study, the first being mood, which is a binary categorical option of either happy or sad. The second variable was rainfall, which is also binary categorical. The rainfall was considered high if the mm of rainfall was greater than 5 mm, and low if less than 5 mm.

library(readr)
MoodRain <- 
  read_csv("~/Documents/math 247 F2023/Rossi Final Project Data Revised.csv")
head(MoodRain, n=2)
round(tally(RainfallBinary~Mood, data = MoodRain, format = "prop"),2) # conditional prop, p-hat values
##               Mood
## RainfallBinary Happy  Sad
##           High  0.32 0.36
##           Low   0.68 0.64

Based on the tallied proportions, the proportional difference between happy and sad responses is relatively small. Even before analysis, there does not seem to be much of a difference between moods when rainfall is high.

High amount of rain Low amount of rain Total
Happy Islander 20 43 63
Sad Islander 9 16 25
Total 29 59 88
mosaicplot(RainfallBinary ~ Mood, data = MoodRain)

What the mosaic plot shows us is that there is a greater amount of low rainfall data points, but that the corresponding proportions between happy and sad are similar for high and low rainfall.

##bargraph(~RainfallBinary, groups = Mood, data = MoodRain, auto.key = TRUE, stack = TRUE)

Analysis of Results

The long run proportion of the population of islanders that were happy when there was high amounts of rain \((π_{highRain})\) vs low amounts of rain \((π_{lowRain})\)

The null hypothesis is that moods don’t differ during high rain days vs low rain days. \[H_0: \pi_{highR}- \pi_{lowR}=0\] The alternative hypothesis is that mood is impacted by high rain amounts vs low rain amounts. \[H_A: \pi_{highR}- \pi_{lowR} \neq 0\]

Based on the research question, in this setting, a type I error would represent an accidental association between mood and rainfall amount when one doesn’t exist. While a type II error would represent assuming that mood and rainfall amount are not associated, but they actually are.

I think the measurements can be considered a representative sample of islanders from Hofn, Ironbard, Maeva, Bonne Santa, and Biruwa, Providence above the age of 5, since that was the scope of the population I picked representatives from. I think this is a representative sample of each of those towns because I selected the islanders with a simple random sampling technique. What my measurements are not a reasonable sample of are Islanders from the islands more generally, or people from the real world.

#sample sizes 

n.highRain<-29 
n.lowRain<-59

#counts 

counts.highRain<-20 
counts.lowRain<-43 
#sample proportions 
p.hat.highRain<-counts.highRain/n.highRain 
p.hat.lowRain<-counts.lowRain/n.lowRain

#difference between the sample proportions of high to low rain
p.hat.diff<-p.hat.highRain-p.hat.lowRain 
cat("difference in sample proportions of people who were happy when there was high rain vs low rain is", p.hat.diff )
## difference in sample proportions of people who were happy when there was high rain vs low rain is -0.03915839
 #pooled proportion (total successes/combined samplesize) 
                                                
p.hat.pooled<-(counts.highRain+counts.lowRain)/(n.highRain +n.lowRain)
#Standard error of the theoretical sampling distribution based on a pooled proportion 
SE.diff.null<-sqrt((p.hat.pooled*(1-p.hat.pooled))/n.highRain + (p.hat.pooled*(1-p.hat.pooled))/n.lowRain) 

#Standardized statistic,z 
z<-p.hat.diff/SE.diff.null 
cat("standardized statistic z is",round(z,2))
## standardized statistic z is -0.38
#Theory-based test p-value 
left.tailed.p.value<-pnorm(z,0,1, lower.tail=TRUE)
right.tailed.p.value<-pnorm(z,0,1,lower.tail=FALSE) 
left.tailed.p.value 
## [1] 0.3509082
#right.tailed.p.value 
#equivalently:
right.tailed.p.value2<-pnorm(p.hat.diff,0,SE.diff.null,lower.tail=FALSE)
#right.tailed.p.value2 
two.sided.p.value<-2*left.tailed.p.value 
cat("two-sided p-value is",two.sided.p.value)
## two-sided p-value is 0.7018165

The two-sided p-value is 0.702, which is quite large, telling us that the probability of observing a difference in proportions as extreme or more extreme than -0.039/0.039 in your null distribution is 70%. This p-value doesn’t meet the threshold for significance of 0.05. We fail to reject the null hypothesis, as we cannot find evidence that the difference in proportions differs from zero. Due to this, we didn’t find evidence to suggest an association between weather and mood for the represented islanders. The validity conditions for the theory-based test were not satisfied (there were 9 observations in the sad islander + high amounts of rain cell of the two-way table), which doesn’t meet the 10 observation minimum. Therefore, a Simulation Based approach must be run instead.

Simulation Based:

set.seed(24601)
moodRain.null <-do(5000) * diffprop(shuffle(Mood) ~ RainfallBinary, success = "Happy",
data = MoodRain)
head(moodRain.null, 2)
p.value<-prop(~(diffprop <=-0.03915839  | diffprop >= 0.03915839), data = moodRain.null)
round(p.value, digits=2)
## prop_TRUE 
##      0.62

The theory-based p-value was 0.70 while the simulation-based p-value was 0.62. The theory-based p-value is slightly larger than the simulation p-value, but neither meet the threshold of significance of 0.05.

tally(RainfallBinary~Mood,data=MoodRain,format="count",margin=TRUE)
##               Mood
## RainfallBinary Happy Sad
##          High     20   9
##          Low      43  16
##          Total    63  25
SE.diff.CI<-sqrt((p.hat.highRain*(1-p.hat.highRain))/n.highRain
              + (p.hat.lowRain*(1-p.hat.lowRain))/n.lowRain)


# margin of error for 95% CI
MoE <- 1.96 * SE.diff.CI
#MoE

LB<-p.hat.diff - MoE # lower limit of 95% CI
UB<-p.hat.diff + MoE # upper limit of 95% CI
round(cbind(LB,UB),2)
##         LB   UB
## [1,] -0.24 0.16

Based on this confidence interval, we can be 95% sure that the proportional difference between islanders who were happy during high rainfall amounts vs sad during high rainfall amounts was between -0.24 and 0.16. Since this interval includes zero, it reinforces my conclusion based on the p-value, that it is possible that the difference in proportions is zero (the proportions for each mood are the same) and that there isn’t an association between mood and amount of rainfall for islanders.

Conclusion

The results of the study show that there is no evidence of association between mood and rainfall amounts for Islanders on Hofn (Iron Bard), Maeva (Bonne Santa), and Biruwa (Providence). This is based on the z-value of -0.38 being so close to the null mean (not even 1 standard deviation away), a very large simulated two-sided p-value of 0.62 that does not meet the threshold for significance, and a confidence interval (-0.24,0.16) that doesn’t include zero. The CI inclusion of zero shows that the difference in proportions between the moods of islanders could be 0 (not differ). All three pieces of evidence provide us with information against rejecting the null hypothesis. Additionally, both the theory based test (which didn’t meet validity conditions) and the simulation test (which had its validity conditions met) returned the same result with each displaying p-values greater than 0.05. The final conclusion that can be reached is that there isn’t evidence to support that rainfall amount has any impact on certain Islander’s daily moods. Again, this is only generalizable to the towns sampled. If I were to repeat this study, I would randomly sample towns from each island to get a more generalizable study. I’d also want to collect data on a wider range of rainfall amounts. Since I collected data in the summer, the rainfall amounts were really low (for even what I catgorized as high in this study). I would make sure to have better rainfall data. I would also in the furture want to use the same sample of people over multiple days, but use a different statistical analyzation technique. To build on these results, someone could look at whether seasons effect mood. They could also take data on temperature’s effect as well. I would also be curious to see whether the Islanders are actually affected by their surroundings, or if the experiments only return null-hypothesis-rejecting-results if the Islanders are manipulated directly.

Bibliography: references to literature mentioned in the introduction

Celia O’Hare, Vincent O’Sullivan, Stephen Flood, Rose Anne Kenny, Seasonal and meteorological associations with depressive symptoms in older adults: A geo-epidemiological study, Journal of Affective Disorders, Volume 191, 2016, Pages 172-179, ISSN 0165-0327, https://doi.org/10.1016/j.jad.2015.11.029

Marcus J.H. Huibers, L. Esther de Graaf, Frenk P.M.L. Peeters, Arnoud Arntz, Does the weather make us sad? Meteorological determinants of mood and depression in the general population, Psychiatry Research, Volume 180, Issues 2–3,2010,Pages 143-146,ISSN 0165-1781,https://doi.org/10.1016/j.psychres.2009.09.016