Introduction
You’ve probably heard these sayings several times, but do they really delay once we have a look at the info? In this text series, I need to take popular myths/sayings and put them to the test using real-world data.
We would confirm some unexpected truths, or debunk some popular beliefs. Hopefully, in either case we’ll gain latest insights into the world around us.
The hypothesis
“An apple a day keeps the doctor away”: is there any real evidence to support this?
If the parable is true, we must always expect a negative correlation between apple consumption per capita and doctor visits per capita . So, the more apples a rustic consumes, the less doctor visits people should need.
Let’s look into the info and see what the numbers really say.
Testing the connection between apple consumption and doctor visits
Let’s start with a straightforward correlation check between apple consumption per capita and doctor visits per capita.
Data sources
The info comes from:
Since data availability varies by 12 months, 2017 was chosen because it provided probably the most complete when it comes to number of nations. Nonetheless, the outcomes are consistent across other years.

Visualizing the connection
To visualise whether higher apple consumption is related to fewer doctor visits, we start by a scatter plot with a regression line.

The regression plot shows a very slim negative correlation, meaning that in countries where people eat more apples, there’s a barely noticeable tendency to have lower doctor visits.
Unfortunately, the trend is so weak that it can’t be considered meaningful.
OLS regression
To check this relationship statistically, we run a linear regression (OLS), where doctor visits per capita is the dependent variable and apple consumption per capita is the independent variable.

The outcomes confirm what the scatterplot suggested:
- The coefficient for apple consumption is -0.0107, meaning that even when there’s an effect, it’s very small.
- The p-value is 0.860 (86%), excess of the usual significance threshold of 5%.
- The R² value is sort of zero, meaning apple consumption explains virtually none of the variation in doctor visits.
This doesn’t strictly mean that there isn’t a relationship, but slightly that we cannot prove one with the available data. It’s possible that any real effect is simply too small to detect, that other aspects we didn’t include play a bigger role, or that the info simply doesn’t reflect the connection well.
Controlling for confounders
Are we done? Not quite. Thus far, we’ve only checked for a direct relationship between apple consumption and doctor visits.
As already mentioned, many other aspects could possibly be influencing each variables, potentially hiding a real relationship or creating a man-made one.
If we consider this causal graph:

We’re assuming that apple consumption directly affects doctor visits. Nonetheless, other hidden aspects may be at play. If we don’t account for them, we risk failing to detect an actual relationship if one exists.
A widely known example where confounder variables are on display comes from a study by Messerli (2012), which found an interesting correlation between chocolate consumption per capita and the variety of Nobel laureates.
So, would beginning to eat numerous chocolate help us win a Nobel Prize? Probably not. The likely explanation was that GDP per capita was a confounder. That implies that richer countries are inclined to have each higher chocolate consumption and more Nobel Prize winners. The observed relationship wasn’t causal but slightly as a result of a hidden (confounding) factor.
The identical thing could possibly be happening in our case. There may be confounding variables that influence each apple consumption and doctor visits, making it difficult to see an actual relationship if one exists.
Two key confounders to think about are GDP per capita and median age. Wealthier countries have higher healthcare systems and different dietary patterns, and older populations are inclined to visit doctors more often and can have different eating habits.
To manage for this, we modify our model by introducing these confounders:

Data sources
The info comes from:


OLS regression (with confounders)
After controlling for GDP per capita and median age, we run a multiple regression to check whether apple consumption has any meaningful effect on doctor visits.

The outcomes confirm what we observed earlier:
- The coefficient for apple consumption stays very small(-0.0100), meaning any potential effect is negligible.
- The p-value (85.5%) remains to be extremely high, removed from statistical significance.
- We still cannot reject the null hypothesis, meaning we’ve no strong evidence to support the concept that eating more apples results in fewer doctor visits.
Same as before, this doesn’t necessarily mean that no relationship exists, but slightly that we cannot prove one using the available data. It could still be possible that the actual effect is simply too small to detect or that there are yet other aspects we didn’t include.
One interesting statement, nevertheless, is that GDP per capita also shows no significant relationship with doctor visits, as its p-value is 0.668 (66.8%), indicating that we couldn’t find in the info that wealth explains variations in healthcare usage.
Then again, median age appears to be strongly related to doctor visits, with a p-value of 0.001 (0.1%) and a positive coefficient (0.4952). This means that older populations are inclined to visit doctors more incessantly, which is definitely not likely surprising if we give it some thought!
So while we discover no support for the apple myth, the info does reveal an interesting relationship between aging and healthcare usage.
Median age → Doctor visits
The outcomes from the OLS regression showed a robust relationship between median age and doctor visits, and the visualization below confirms this trend.

There may be a transparent upward trend, indicating that countries with older populations are inclined to have more doctor visits per capita.
Since we’re only median age and doctor visits here, one could argue that GDP per capita may be a confounder, influencing each. Nonetheless, the previous OLS regression demonstrated that even when GDP was included within the model, this relationship remained strong and statistically significant.
This means that median age is a key consider explaining differences in doctor visits across countries, independent of GDP.
GDP → Apple consumption
While indirectly related to doctor visits, an interesting secondary finding emerges when the connection between GDP per capita and apple consumption.
One possible explanation is that wealthier countries have higher access to fresh products. One other possibility is that climate and geography play a task, so it could possibly be that many high-GDP countries are positioned in regions with strong apple production, making apples more available and reasonably priced.
After all, other aspects could possibly be influencing this relationship, but we won’t dig deeper here.

The scatterplot shows a positive correlation: as GDP per capita increases, apple consumption also tends to rise. Nonetheless, in comparison with median age and doctor visits, this trend is weaker, with more variation in the info.

The OLS confirms the connection: with a 0.2257 coefficient for GDP per capita, we are able to estimate a rise of around 0.23 kg in apple consumption per capita for every increase of $1,000 in GDP per capita.
The three.8% p-value allows us to reject the null hypothesis. So the connection is statistically significant. Nonetheless, the R² value (0.145) is comparatively low, so while GDP explains some variation in apple consumption, many other aspects likely contribute.
Conclusion
The saying goes:
But after putting this myth to the test with real-world data, the outcomes seem not in step with this saying. Across multiple years, the outcomes were consistent: no meaningful relationship between apple consumption and doctor visits emerged, even after controlling for confounders. It appears that evidently apples alone aren’t enough to maintain the doctor away.
Nonetheless, this doesn’t completely disprove the concept that eating more apples could reduce doctor visits. Observational data, regardless of how well we control for confounders, can never fully prove or disprove causality.
To get a more statistically accurate answer, and to rule out all possible confounders at a level of granularity that could possibly be actionable for a person, we would wish to conduct an A/B test.
In such an experiment, participants could be randomly assigned to 2 groups, for instance one eating a set amount of apples every day and the opposite avoiding apples. By comparing doctor visits over time amongst these two groups, we could determine if any difference between them arise, providing stronger evidence of a causal effect.
For obvious reasons, I selected to not go that route. Hiring a bunch of participants could be expensive, and ethically forcing people to avoid apples for science is certainly questionable.
Nonetheless, we did find some interesting patterns. The strongest predictor of doctor visits wasn’t apple consumption, but median age: the older a rustic’s population, the more often people see a physician.
Meanwhile, GDP showed a gentle connection to apple consumption, possibly because wealthier countries have higher access to fresh produce, or because apple-growing regions are inclined to be more developed.
So, while we are able to’t confirm the unique myth, we are able to offer a less poetic, but data-backed version:
“A young age keeps the doctor away.”
In the event you enjoyed this evaluation and need to attach, you will discover me on LinkedIn.
The complete evaluation is on the market on this notebook on GitHub.
Data Sources
Fruit Consumption: Food and Agriculture Organization of the United Nations (2023) — with major processing by Our World in Data. “Per capita consumption of apples — FAO” [dataset]. Food and Agriculture Organization of the United Nations, “Food Balances: Food Balances (-2013, old methodology and population)”; Food and Agriculture Organization of the United Nations, “Food Balances: Food Balances (2010-)” [original data]. Licensed under CC BY 4.0.
Doctor Visits: OECD (2024), Consultations, URL (accessed on January 22, 2025). Licensed under CC BY 4.0.
GDP per Capita: World Bank (2025) — with minor processing by Our World in Data. “GDP per capita — World Bank — In constant 2021 international $” [dataset]. World Bank, “World Bank World Development Indicators” [original data]. Retrieved January 31, 2025 from https://ourworldindata.org/grapher/gdp-per-capita-worldbank. Licensed under CC BY 4.0.
Median Age: UN, World Population Prospects (2024) — processed by Our World in Data. “Median age, medium projection — UN WPP” [dataset]. United Nations, “World Population Prospects” [original data]. Licensed under CC BY 4.0.
All images, unless otherwise noted, are by the writer.