about · email me · subscribe
Spurious correlation #3,515 · View random

A linear line chart with years as the X-axis and two variables on the Y-axis. The first variable is Air pollution in Milwaukee and the second variable is Kerosene used in Peru.  The chart goes from 1980 to 2021, and the two variables track closely in value over that time. Small Image
Download png
, svg

AI explanation

As air pollution decreased in Milwaukee, it created a ripple effect in the atmosphere, leading to a shift in kerosene-carrying air currents. This unintentional kerosene transport system, which I like to call the "Eau de Milwaukee to Lima Express," has been significantly disrupted. It turns out Mother Nature was just trying to Marie Kondo the skies, sparking joy by decluttering kerosene and sending it off to spark joy elsewhere.

Model: dalle-3
Prompt: Generate an image that combines the contrasting scenes of air pollution in Milwaukee and the use of kerosene in Peru. Depict the Milwaukee skyline veiled in thick smog with cars and factories emitting billows of pollution into the air. Show the dimly lit Peruvian village with families gathering around kerosene lamps, emphasizing the juxtaposition of a high-tech, industrialized city and a quaint, traditional setting. Create a stark contrast between the two settings, highlighting the impact of air pollution on vastly different communities. Ensure that the visual remains simple and does not include any words or speech bubbles. The depiction should include only scenes, people, and objects, it should not include text or speech bubbles.
This image generation prompt was also generated by AI, using the following sequence:

Model: gpt-3.5-turbo-1106
System prompt: You select one of a few potential scene descriptors that seems to go along with the variables described. You respond only with the scene descriptions provided and say nothing else.
User prompt: Here are two variables: Air pollution in Milwaukee and Kerosene used in Peru. Given these, which of the following image style descriptions seems most appropriate? Pick the one that seems to be related to one of the variables at hand. Please respond with only one of the following potential descriptions: Art nouveau Cute 2D animation Cute cartoon High-tech a funny image macro
ChatGPT: Air pollution in Milwaukee: High-tech Kerosene used in Peru: Cute cartoon

Model: gpt-3.5-turbo-1106
System prompt: You describe simple visual scenes that depict the two variables stated. You combine both variables into one scene.
User prompt: Please describe a visual scene that prominently depicts both Air pollution in Milwaukee and Kerosene used in Peru, in the following situation: The increase in air pollution in Milwaukee led to a surge in demand for air fresheners, causing a shortage of kerosene in Peru. People there started using kerosene to mask the smell of pollution, leading to the unexpected correlation.. Keep the description simple.
ChatGPT: In Milwaukee, the city skyline is shrouded in smog as cars and factories emit thick clouds of pollution into the air. Meanwhile, in a small Peruvian village, families are gathered around dimly lit kerosene lamps, using them not just for light, but also to mask the unpleasant scent of the polluted air that has been carried across the ocean.

Model: gpt-3.5-turbo-1106
System prompt: You write and improve image generation prompts for DALLE-3. You maintain the same subjects, but enhance the visuals.
User prompt: Please respond with an image generation prompt that would be likely to create an interesting visual using DALLE-3, using the following style: [ Air pollution in Milwaukee: High-tech Kerosene used in Peru: Cute cartoon ] and depicting this scene: In Milwaukee, the city skyline is shrouded in smog as cars and factories emit thick clouds of pollution into the air. Meanwhile, in a small Peruvian village, families are gathered around dimly lit kerosene lamps, using them not just for light, but also to mask the unpleasant scent of the polluted air that has been carried across the ocean. Keep the visual depiction simple. Do not include any words or speech bubbles.
ChatGPT: Generate an image that combines the contrasting scenes of air pollution in Milwaukee and the use of kerosene in Peru. Depict the Milwaukee skyline veiled in thick smog with cars and factories emitting billows of pollution into the air. Show the dimly lit Peruvian village with families gathering around kerosene lamps, emphasizing the juxtaposition of a high-tech, industrialized city and a quaint, traditional setting. Create a stark contrast between the two settings, highlighting the impact of air pollution on vastly different communities. Ensure that the visual remains simple and does not include any words or speech bubbles.

*Variations in the User Prompts from chart to chart are just the result of random number generation in Python. I wrote a few arrays of various styles and methods to ask questions to change up the results. Every time this site writes an explanation or generates an image, the script picks from each at random.

I sequence the requests into multiple prompts because I find GPT 3.5 to perform much better with short, well-managed contexts. Thus, I track the context directly in Python and only ask ChatGPT targeted questions.

Model: gpt-3.5-turbo-1106 (fine-tuned)
System prompt: You provide humorous responses in the form of plausible sounding explanations for correlations. You assume the correlation is causative for the purpose of the explanation even if it is ridiculous. You do not chat with the user, you only reply with the causal connection explanation and nothing else.
User prompt: Please make up a funny explanation for how a decrease in Air pollution in Milwaukee caused Kerosene used in Peru to decrease.

AI academic paper

(Because p < 0.01)
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

The Journal of Eclectic Environmental Analytics

Jan 2024

Reminder: This paper is AI-generated. Not real!
Quick note: This sequence is long and repetitive. That's how the prompt engineering works for this one. I manage the output in Python to format it into this PDF.




Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You write titles and abstracts of goofy academic research papers.
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, and add unexpected twists in your writing.

Please draft the title and abstract of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns.

Rhyme words in the title.

Your research team used data from Environmental Protection Agency and Energy Information Administration to assess this nagging question. You found a correlation coefficient of 0.7945856 and p < 0.01 for 1980 to 2021.

Please respond in this format (replace "Lorem ipsum dolor sit" with your title and abstract)

[[TITLE]]
Lorem ipsum dolor sit

[[ABSTRACT]]
Lorem ipsum dolor sit



ChatGPT:
[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!


Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You draft the introduction section of an academic research paper.
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, or add unexpected twists in your writing.

Please make up the introduction section of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns. Sneak in some jokes and clever puns about science, research, statistics, and the variables.

Here is the title and abstract of the paper:
[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

-------

Your response should start like this:

[[INTRODUCTION]]



ChatGPT:
[[INTRODUCTION]]

Welcome, fellow intellectuals and inquisitive minds, to a thoroughly enlightening exploration of the intersection of air pollution in Milwaukee and the use of kerosene, a tale not merely about two distant points on the globe, but a saga of statistical significance, real-world impact, and perhaps, a touch of cosmic interconnectedness.

Our story begins with the twinning of two seemingly unrelated elements: the smog-choked skies of Milwaukee, and the distant flickering glow of kerosene lamps in Peru. While these may appear as disparate as sodium and chlorine, our zealous band of statisticians, armed with data from the Environmental Protection Agency and the Energy Information Administration, embarked on a journey of discovery. The road less traveled was not taken, for it was obscured by the haze of urban air pollution – and undaunted, we forged ahead.

The premise of this investigation arose from a peculiar notion that beneath the dense layers of particulate matter, carbon monoxide, and nitrogen dioxide, a hidden thread, woven in the fabric of global interconnectedness, might connect these two seemingly distant phenomena. Our quest for truth and understanding was propelled by the intuition that the world of air pollution and the realm of kerosene usage, though oceans apart, might just be cosmically entwined.

Armed with our trusty statistical tools, we meticulously traversed the labyrinth of data, probing, prodding, and peering into the mists of uncertainty. Lo and behold, what emerged was a correlation coefficient of 0.7945856, a figure robustly suggesting that these two disparate domains of environmental concern were not merely ships passing in the night. Behold the p-value, less than 0.01, a beacon of statistical significance illuminating our path forward.

As we unravel the tapestry of our findings, we invite you to embrace the enigmatic truth that the flicker of a kerosene lamp in Peru can cast its glow across the vast expanse of time and space, reaching across continents to influence the air that the denizens of Milwaukee breathe. So, dear reader, hold onto your hypotheses and buckle up for a statistical stroll through the unexpected nexus of air pollution in Milwaukee and the humble kerosene lamp in Peru. This is not just another research paper; it's a lighthearted romp through the wilds of statistical surprises.

In the words of our dearly beloved Sir Isaac Newton, "If I have seen further, it is by standing on the shoulders of giants" – and perhaps, a subtle nudge from statistical anomalies. Let the investigation unfold and may the outliers guide us to the heart of this conundrum.


Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You draft a literature review section of an academic research paper, that starts out dry for the first few sentences but then becomes hilarious and goofy.
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, or add unexpected twists in your writing.

Please make up a literature review section of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns.

Speak in the present tense for this section (the authors find...), as is common in academic research paper literature reviews. Name the sources in a format similar to this: In "Book," the authors find lorem and ipsum.

Make up the lorem and ipsum part, but make it sound related to the topic at hand.

Start by naming serious-sounding studies by authors like Smith, Doe, and Jones - but then quickly devolve. Name some real non-fiction books that would be related to the topic. Then name some real fiction books that sound like they could be related. Perhaps you also got inspiration from some board games that are vaugely related.

Here is the title and abstract of the paper:
[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

-------

And here is the introduction section that led to this literature review:
[[INTRODUCTION]]
Welcome, fellow intellectuals and inquisitive minds, to a thoroughly enlightening exploration of the intersection of air pollution in Milwaukee and the use of kerosene, a tale not merely about two distant points on the globe, but a saga of statistical significance, real-world impact, and perhaps, a touch of cosmic interconnectedness.
Our story begins with the twinning of two seemingly unrelated elements: the smog-choked skies of Milwaukee, and the distant flickering glow of kerosene lamps in Peru. While these may appear as disparate as sodium and chlorine, our zealous band of statisticians, armed with data from the Environmental Protection Agency and the Energy Information Administration, embarked on a journey of discovery. The road less traveled was not taken, for it was obscured by the haze of urban air pollution – and undaunted, we forged ahead.
The premise of this investigation arose from a peculiar notion that beneath the dense layers of particulate matter, carbon monoxide, and nitrogen dioxide, a hidden thread, woven in the fabric of global interconnectedness, might connect these two seemingly distant phenomena. Our quest for truth and understanding was propelled by the intuition that the world of air pollution and the realm of kerosene usage, though oceans apart, might just be cosmically entwined.
Armed with our trusty statistical tools, we meticulously traversed the labyrinth of data, probing, prodding, and peering into the mists of uncertainty. Lo and behold, what emerged was a correlation coefficient of 0.7945856, a figure robustly suggesting that these two disparate domains of environmental concern were not merely ships passing in the night. Behold the p-value, less than 0.01, a beacon of statistical significance illuminating our path forward.
As we unravel the tapestry of our findings, we invite you to embrace the enigmatic truth that the flicker of a kerosene lamp in Peru can cast its glow across the vast expanse of time and space, reaching across continents to influence the air that the denizens of Milwaukee breathe. So, dear reader, hold onto your hypotheses and buckle up for a statistical stroll through the unexpected nexus of air pollution in Milwaukee and the humble kerosene lamp in Peru. This is not just another research paper; it's a lighthearted romp through the wilds of statistical surprises.
In the words of our dearly beloved Sir Isaac Newton, "If I have seen further, it is by standing on the shoulders of giants" – and perhaps, a subtle nudge from statistical anomalies. Let the investigation unfold and may the outliers guide us to the heart of this conundrum.

-------

Your response should start like this:

[[LITERATURE REVIEW]]



ChatGPT:
[[LITERATURE REVIEW]]

The connection between air pollution in industrialized cities and the use of kerosene in developing countries is an area that has been relatively unexplored in the academic literature. However, recent studies have shed light on this unexpected relationship, prompting a re-evaluation of our understanding of environmental interconnectedness.

Smith and Doe (2018) conducted a comprehensive analysis of air pollution in urban centers, examining the impact of industrial emissions, vehicular traffic, and other key contributors to atmospheric degradation. While their focus was primarily on local sources of pollution, their findings hinted at a broader network of influences that extended beyond the city limits. Jones (2019) delved into the intricate web of energy consumption patterns in rural areas, emphasizing the prevalence of kerosene as a primary source of lighting in regions without access to electricity. Their work highlighted the reliance on traditional fuels and the implications for indoor and outdoor air quality.

In a similar vein, "The Economics of Air Pollution" by Brown et al. (2020) offered a macroeconomic perspective on the societal costs of air pollution, encompassing health impacts, productivity losses, and environmental degradation. While their analysis centered on economic valuation, the indirect effects of global air pollution transcended national boundaries, laying the groundwork for an interdisciplinary exploration of cross-border influences. Transitioning into a more speculative realm, "The Airborne Adventures of Professor P." by A. Novel (2017) presented a fictional account of a quirky scientist's quest to unravel the mysteries of air pollution, complete with whimsical anecdotes and scientific curiosities. Though the book's focus was firmly rooted in the realm of imagination, it served as a reminder that the study of air quality need not be devoid of levity.

On the periphery of this topic, "Lighting the Way: Transforming Lives with Kerosene" by Glow et al. (2015) provided a firsthand account of the challenges and triumphs associated with kerosene usage in rural communities. The authors painted a vivid picture of the social and cultural significance of kerosene lamps, acknowledging their dual role as illuminators of darkness and unwitting contributors to indoor air pollution. Taking a playful turn, "Clue: The Mystery of the Polluted Parlor" by B. Game (2000) may seem an unlikely source of insight, yet its narrative of environmental sleuthing and deductive reasoning offers a metaphorical perspective on the elusive connections we seek to uncover.

By synthesizing these diverse perspectives, the authors find themselves poised at the precipice of an unconventional union between air pollution in Milwaukee and kerosene usage in Peru. As the investigation unfolds, it becomes increasingly apparent that this unexpected symbiosis transcends the boundaries of conventional environmental thinking, beckoning towards a more whimsical and interconnected understanding of our planet. Stay tuned for the empirical evidence that promises not only to illuminate our intellects but also to infuse a bit of mirth into the world of environmental research.


Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You draft the methodology section of an academic research paper.
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, or add unexpected twists in your writing.

Please make up the methodology section of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns. Sneak in some jokes and clever puns about science, research, statistics, and the variables.

Your research team collected data from all across the internet, but mostly just used information from Environmental Protection Agency and Energy Information Administration . You used data from 1980 to 2021

Make up the research methods you don't know. Make them a bit goofy and convoluted.

Here is the title, abstract, and introduction of the paper:
[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

[[INTRODUCTION]]
Welcome, fellow intellectuals and inquisitive minds, to a thoroughly enlightening exploration of the intersection of air pollution in Milwaukee and the use of kerosene, a tale not merely about two distant points on the globe, but a saga of statistical significance, real-world impact, and perhaps, a touch of cosmic interconnectedness.
Our story begins with the twinning of two seemingly unrelated elements: the smog-choked skies of Milwaukee, and the distant flickering glow of kerosene lamps in Peru. While these may appear as disparate as sodium and chlorine, our zealous band of statisticians, armed with data from the Environmental Protection Agency and the Energy Information Administration, embarked on a journey of discovery. The road less traveled was not taken, for it was obscured by the haze of urban air pollution – and undaunted, we forged ahead.
The premise of this investigation arose from a peculiar notion that beneath the dense layers of particulate matter, carbon monoxide, and nitrogen dioxide, a hidden thread, woven in the fabric of global interconnectedness, might connect these two seemingly distant phenomena. Our quest for truth and understanding was propelled by the intuition that the world of air pollution and the realm of kerosene usage, though oceans apart, might just be cosmically entwined.
Armed with our trusty statistical tools, we meticulously traversed the labyrinth of data, probing, prodding, and peering into the mists of uncertainty. Lo and behold, what emerged was a correlation coefficient of 0.7945856, a figure robustly suggesting that these two disparate domains of environmental concern were not merely ships passing in the night. Behold the p-value, less than 0.01, a beacon of statistical significance illuminating our path forward.
As we unravel the tapestry of our findings, we invite you to embrace the enigmatic truth that the flicker of a kerosene lamp in Peru can cast its glow across the vast expanse of time and space, reaching across continents to influence the air that the denizens of Milwaukee breathe. So, dear reader, hold onto your hypotheses and buckle up for a statistical stroll through the unexpected nexus of air pollution in Milwaukee and the humble kerosene lamp in Peru. This is not just another research paper; it's a lighthearted romp through the wilds of statistical surprises.
In the words of our dearly beloved Sir Isaac Newton, "If I have seen further, it is by standing on the shoulders of giants" – and perhaps, a subtle nudge from statistical anomalies. Let the investigation unfold and may the outliers guide us to the heart of this conundrum.

-------

Your response should start like this:

[[METHODOLOGY]]



ChatGPT:

[[METHODOLOGY]]

To concoct our statistical stew of interconnectedness, we employed a rather eclectic mix of research methods and statistical analyses. Our data collection transcended geographical boundaries, spanning the vast expanses of the internet, and zeroed in on the repositories of wisdom known as the Environmental Protection Agency and the Energy Information Administration. We sifted through an array of datasets spanning the years 1980 to 2021, diligently seeking the hidden patterns that might bind the air pollution of Milwaukee and the illuminating glow of kerosene in Peru.

Our first step involved a rigorous exploration of the air pollution data in Milwaukee, delving into the minutiae of particulate matter, sulfur dioxide, carbon monoxide, and nitrogen dioxide levels. Armed with spreadsheets and a tad too much coffee, we navigated the intellectual stratosphere of correlation analyses, seeking to discern any tantalizing interplay between the air quality metrics and our enigmatic variable from the distant land of Peru.

Turning our gaze toward kerosene, we embarked on a mini-expedition into the esoteric world of energy consumption in Peru. Despite facing the labyrinthine complexities of energy data, we emerged unscathed, armed with insights into kerosene consumption patterns. The flickering flames of kerosene lamps held within their glow the promise of a statistical narrative that danced in the wind like a mercury bulb.

Guided by our trusty statistical compass, we summoned the powers of correlation analysis to ascertain whether the two disparate worlds of air pollution in Milwaukee and kerosene usage in Peru shared a cosmic handshake. Our statistical voyage was graced by the stately presence of the correlation coefficient, accompanied by the ethereal grace of the p-value, both of which enkindled our research with the radiance of statistical significance.

Moreover, we employed a robust regression analysis to disentangle the complex web of variables, teasing out the subtle threads that wove the tale of interconnectedness between these seemingly distant phenomena. As we traversed the realm of statistical significance, we were ever vigilant, warding off the mischievous outliers and herding the elusive clusters of data with the finesse of a statistical shepherd.

In conclusion, our methodology exhibited a veritable tapestry of statistical intricacies, interwoven with the impish charm of data exploration, yielding insights that defied the conventional boundaries of environmental analysis. The journey from the smog-filled skies of Milwaukee to the flickering glow of kerosene lamps in Peru was not merely a pedestrian statistical exercise but a rollicking adventure that transcended the confines of traditional research. And yes, we have the data to prove it!


Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You draft the results section of an academic research paper. You speak in the past tense (you found...).
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, or add unexpected twists in your writing.

Please make up the results section of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns. Sneak in some jokes and clever puns about science, research, statistics, and the variables.

Your research team collected data from all across the internet, but mostly just used information from Environmental Protection Agency and Energy Information Administration .

For the time period 1980 to 2021, you found a correlation 0.7945856, r-squared of 0.6313662, and p < 0.01.

One figure will be included. The figure (Fig. 1) is a scatterplot showing the strong correlation between the two variables. You don't need to specify where; I will add the figure.

Here is the title and abstract of the paper:
[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

-------

And here is the methodology section that led to this result:
[[METHODOLOGY]]
Welcome, fellow intellectuals and inquisitive minds, to a thoroughly enlightening exploration of the intersection of air pollution in Milwaukee and the use of kerosene, a tale not merely about two distant points on the globe, but a saga of statistical significance, real-world impact, and perhaps, a touch of cosmic interconnectedness.
Our story begins with the twinning of two seemingly unrelated elements: the smog-choked skies of Milwaukee, and the distant flickering glow of kerosene lamps in Peru. While these may appear as disparate as sodium and chlorine, our zealous band of statisticians, armed with data from the Environmental Protection Agency and the Energy Information Administration, embarked on a journey of discovery. The road less traveled was not taken, for it was obscured by the haze of urban air pollution – and undaunted, we forged ahead.
The premise of this investigation arose from a peculiar notion that beneath the dense layers of particulate matter, carbon monoxide, and nitrogen dioxide, a hidden thread, woven in the fabric of global interconnectedness, might connect these two seemingly distant phenomena. Our quest for truth and understanding was propelled by the intuition that the world of air pollution and the realm of kerosene usage, though oceans apart, might just be cosmically entwined.
Armed with our trusty statistical tools, we meticulously traversed the labyrinth of data, probing, prodding, and peering into the mists of uncertainty. Lo and behold, what emerged was a correlation coefficient of 0.7945856, a figure robustly suggesting that these two disparate domains of environmental concern were not merely ships passing in the night. Behold the p-value, less than 0.01, a beacon of statistical significance illuminating our path forward.
As we unravel the tapestry of our findings, we invite you to embrace the enigmatic truth that the flicker of a kerosene lamp in Peru can cast its glow across the vast expanse of time and space, reaching across continents to influence the air that the denizens of Milwaukee breathe. So, dear reader, hold onto your hypotheses and buckle up for a statistical stroll through the unexpected nexus of air pollution in Milwaukee and the humble kerosene lamp in Peru. This is not just another research paper; it's a lighthearted romp through the wilds of statistical surprises.
In the words of our dearly beloved Sir Isaac Newton, "If I have seen further, it is by standing on the shoulders of giants" – and perhaps, a subtle nudge from statistical anomalies. Let the investigation unfold and may the outliers guide us to the heart of this conundrum.

-------

Your response should start like this:

[[RESULTS]]



ChatGPT:

[[RESULTS]]

The findings of our study revealed a correlation coefficient of 0.7945856 and an r-squared of 0.6313662, indicating a strong positive relationship between air pollution in Milwaukee and the use of kerosene in Peru from 1980 to 2021. The p-value of less than 0.01 further underscored the statistical significance of this unexpected connection. In essence, our data suggests that as kerosene usage in Peru fluctuated, air pollution levels in Milwaukee were also notably affected.

To visually capture this unexpected alliance, we present Fig. 1, a scatterplot exemplifying the strong correlation between these seemingly unrelated variables. A picture is worth a thousand data points, after all.

So, next time you're debating the pros and cons of kerosene usage, remember that the impact might just extend further than the flickering glow of a distant lamp—it could have implications for air quality halfway around the world!

These results challenge the conventional wisdom and ignite a lively discussion on the interplay between seemingly disparate environmental factors. The statistical stroll has unveiled an intriguing phenomenon that bears further investigation and consideration in the realm of environmental policy and global interconnectedness.

Our team is elated to have unraveled this tale of statistical surprise and hopes that this study will inspire further exploration into the underpinnings of environmental interdependence. Now, we're left pondering: what other unexpected connections might statistics reveal, lurking in the depths of data and variables?


Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You draft the discussion section of an academic research paper.
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, or add unexpected twists in your writing.

Please make up the discussion section of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns. Sneak in some jokes and clever puns about science, research, statistics, and the variables.

Limit your response to 500 tokens.

Here are the title, abstract, literature review, and results sections. Please harken back to 1-2 of the goofy items in the literature review, but pretend to take them completely seriously. Discuss how your results supported the prior research.

Do not write a conclusion. I will add a conclusion after this.

[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

[[LITERATURE REVIEW]]
The connection between air pollution in industrialized cities and the use of kerosene in developing countries is an area that has been relatively unexplored in the academic literature. However, recent studies have shed light on this unexpected relationship, prompting a re-evaluation of our understanding of environmental interconnectedness.
Smith and Doe (2018) conducted a comprehensive analysis of air pollution in urban centers, examining the impact of industrial emissions, vehicular traffic, and other key contributors to atmospheric degradation. While their focus was primarily on local sources of pollution, their findings hinted at a broader network of influences that extended beyond the city limits. Jones (2019) delved into the intricate web of energy consumption patterns in rural areas, emphasizing the prevalence of kerosene as a primary source of lighting in regions without access to electricity. Their work highlighted the reliance on traditional fuels and the implications for indoor and outdoor air quality.
In a similar vein, "The Economics of Air Pollution" by Brown et al. (2020) offered a macroeconomic perspective on the societal costs of air pollution, encompassing health impacts, productivity losses, and environmental degradation. While their analysis centered on economic valuation, the indirect effects of global air pollution transcended national boundaries, laying the groundwork for an interdisciplinary exploration of cross-border influences. Transitioning into a more speculative realm, "The Airborne Adventures of Professor P." by A. Novel (2017) presented a fictional account of a quirky scientist's quest to unravel the mysteries of air pollution, complete with whimsical anecdotes and scientific curiosities. Though the book's focus was firmly rooted in the realm of imagination, it served as a reminder that the study of air quality need not be devoid of levity.
On the periphery of this topic, "Lighting the Way: Transforming Lives with Kerosene" by Glow et al. (2015) provided a firsthand account of the challenges and triumphs associated with kerosene usage in rural communities. The authors painted a vivid picture of the social and cultural significance of kerosene lamps, acknowledging their dual role as illuminators of darkness and unwitting contributors to indoor air pollution. Taking a playful turn, "Clue: The Mystery of the Polluted Parlor" by B. Game (2000) may seem an unlikely source of insight, yet its narrative of environmental sleuthing and deductive reasoning offers a metaphorical perspective on the elusive connections we seek to uncover.
By synthesizing these diverse perspectives, the authors find themselves poised at the precipice of an unconventional union between air pollution in Milwaukee and kerosene usage in Peru. As the investigation unfolds, it becomes increasingly apparent that this unexpected symbiosis transcends the boundaries of conventional environmental thinking, beckoning towards a more whimsical and interconnected understanding of our planet. Stay tuned for the empirical evidence that promises not only to illuminate our intellects but also to infuse a bit of mirth into the world of environmental research.

[[RESULTS]]
The findings of our study revealed a correlation coefficient of 0.7945856 and an r-squared of 0.6313662, indicating a strong positive relationship between air pollution in Milwaukee and the use of kerosene in Peru from 1980 to 2021. The p-value of less than 0.01 further underscored the statistical significance of this unexpected connection. In essence, our data suggests that as kerosene usage in Peru fluctuated, air pollution levels in Milwaukee were also notably affected.
To visually capture this unexpected alliance, we present Fig. 1, a scatterplot exemplifying the strong correlation between these seemingly unrelated variables. A picture is worth a thousand data points, after all.
So, next time you're debating the pros and cons of kerosene usage, remember that the impact might just extend further than the flickering glow of a distant lamp—it could have implications for air quality halfway around the world!
These results challenge the conventional wisdom and ignite a lively discussion on the interplay between seemingly disparate environmental factors. The statistical stroll has unveiled an intriguing phenomenon that bears further investigation and consideration in the realm of environmental policy and global interconnectedness.
Our team is elated to have unraveled this tale of statistical surprise and hopes that this study will inspire further exploration into the underpinnings of environmental interdependence. Now, we're left pondering: what other unexpected connections might statistics reveal, lurking in the depths of data and variables?

-------

Your response should start like this:

[[DISCUSSION]]



ChatGPT:

[[DISCUSSION]]

The results of our study not only cement the unexpected relationship between air pollution in Milwaukee and kerosene usage in Peru but also serve as a testament to the potential for statistical delight in the realm of environmental research. While our findings may seem dazzlingly improbable at first glance, they are firmly grounded in the melodious chorus of previous scholarship that hinted at this curious interconnectedness.

Going back to the "The Airborne Adventures of Professor P." by A. Novel (2017), the whimsical anecdotes and scientific curiosities, while fictional, piqued our interest and kindled a spirit of inquiry that has permeated our investigation. Similarly, the "Clue: The Mystery of the Polluted Parlor" by B. Game (2000), initially an unlikely source of insight, metaphorically resonates with our endeavor to unravel the enigmatic threads of environmental interconnectedness.

The strong positive relationship highlighted in our results aligns harmoniously with the astronomical correlation coefficient, making this connection not just statistically significant but also profoundly engaging. The visual representation in our scatterplot (Fig. 1) serves as a vivid illustration of the symphonic choreography between air pollution in Milwaukee and kerosene usage in Peru.

These unexpected findings remind us that the world of environmental research is rife with undiscovered melodies, awaiting the keen ears of diligent statisticians. The echoes of this unlikely duet compel us to rethink our understanding of regional environmental influences and beckon toward a more harmonious and interconnected approach to environmental policy.

In the words of "The Economics of Air Pollution" by Brown et al. (2020), the indirect effects of global air pollution indeed transcend national boundaries, creating a crescendo of awareness that demands attention and action. Our results not only corroborate the speculative intuition but provide hard evidence in support of the notion that seemingly distant environmental factors can dance together in statistical harmony.

As we serenade the prospect of future research endeavors, we are left humbled by the illuminating potential of unexpected statistical connections and buoyed by the hope that our study will inspire a chorus of inquiry into the allegro vivace of environmental interdependence.


Model: gpt-3.5-turbo-1106
System prompt: You are a researcher writing an academic paper.You draft the discussion section of goofy academic research papers that sounds like it belongs based on the title and abstract provided.
User prompt:
Pretend you are an academic researcher. Your writing sounds like it belongs in a medical or economics journal. However, you frequently crack jokes, make puns, or add unexpected twists in your writing.

Please make up a short conclusion of an academic research paper presenting the findings of the connection between Air pollution in Milwaukee and Kerosene used in Peru. Make it seem dry like academic research paper, but with lots of subtle hidden offhand remarks, jokes, goofy observations, and puns. Sneak in some jokes and clever puns about science, research, statistics, and the variables.

Limit your response to 300 tokens. At the very end, assert that no more research is needed in this area.

Here are the title, abstract, introduction, and results sections.
[[TITLE]]
Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll

[[ABSTRACT]]
This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

[[INTRDUCTION]]
Welcome, fellow intellectuals and inquisitive minds, to a thoroughly enlightening exploration of the intersection of air pollution in Milwaukee and the use of kerosene, a tale not merely about two distant points on the globe, but a saga of statistical significance, real-world impact, and perhaps, a touch of cosmic interconnectedness.
Our story begins with the twinning of two seemingly unrelated elements: the smog-choked skies of Milwaukee, and the distant flickering glow of kerosene lamps in Peru. While these may appear as disparate as sodium and chlorine, our zealous band of statisticians, armed with data from the Environmental Protection Agency and the Energy Information Administration, embarked on a journey of discovery. The road less traveled was not taken, for it was obscured by the haze of urban air pollution – and undaunted, we forged ahead.
The premise of this investigation arose from a peculiar notion that beneath the dense layers of particulate matter, carbon monoxide, and nitrogen dioxide, a hidden thread, woven in the fabric of global interconnectedness, might connect these two seemingly distant phenomena. Our quest for truth and understanding was propelled by the intuition that the world of air pollution and the realm of kerosene usage, though oceans apart, might just be cosmically entwined.
Armed with our trusty statistical tools, we meticulously traversed the labyrinth of data, probing, prodding, and peering into the mists of uncertainty. Lo and behold, what emerged was a correlation coefficient of 0.7945856, a figure robustly suggesting that these two disparate domains of environmental concern were not merely ships passing in the night. Behold the p-value, less than 0.01, a beacon of statistical significance illuminating our path forward.
As we unravel the tapestry of our findings, we invite you to embrace the enigmatic truth that the flicker of a kerosene lamp in Peru can cast its glow across the vast expanse of time and space, reaching across continents to influence the air that the denizens of Milwaukee breathe. So, dear reader, hold onto your hypotheses and buckle up for a statistical stroll through the unexpected nexus of air pollution in Milwaukee and the humble kerosene lamp in Peru. This is not just another research paper; it's a lighthearted romp through the wilds of statistical surprises.
In the words of our dearly beloved Sir Isaac Newton, "If I have seen further, it is by standing on the shoulders of giants" – and perhaps, a subtle nudge from statistical anomalies. Let the investigation unfold and may the outliers guide us to the heart of this conundrum.

[[RESULTS]]
The findings of our study revealed a correlation coefficient of 0.7945856 and an r-squared of 0.6313662, indicating a strong positive relationship between air pollution in Milwaukee and the use of kerosene in Peru from 1980 to 2021. The p-value of less than 0.01 further underscored the statistical significance of this unexpected connection. In essence, our data suggests that as kerosene usage in Peru fluctuated, air pollution levels in Milwaukee were also notably affected.
To visually capture this unexpected alliance, we present Fig. 1, a scatterplot exemplifying the strong correlation between these seemingly unrelated variables. A picture is worth a thousand data points, after all.
So, next time you're debating the pros and cons of kerosene usage, remember that the impact might just extend further than the flickering glow of a distant lamp—it could have implications for air quality halfway around the world!
These results challenge the conventional wisdom and ignite a lively discussion on the interplay between seemingly disparate environmental factors. The statistical stroll has unveiled an intriguing phenomenon that bears further investigation and consideration in the realm of environmental policy and global interconnectedness.
Our team is elated to have unraveled this tale of statistical surprise and hopes that this study will inspire further exploration into the underpinnings of environmental interdependence. Now, we're left pondering: what other unexpected connections might statistics reveal, lurking in the depths of data and variables?

-------

Your response should start like this:

[[CONCLUSION]]



ChatGPT:

[[CONCLUSION]]

In conclusion, our statistically illuminating exploration has brought to light a seemingly cosmic link between air pollution in Milwaukee and kerosene usage in Peru. The robust correlation coefficient and p-value emphasize the unsuspected connection between these two disparate environmental realms. It's a real "light bulb" moment, where we've witnessed the impact of kerosene use on air quality reach across continents, much like a whimsical game of environmental tag. This unexpected nexus challenges our perceptions of the interconnectedness of global environmental factors and raises the delightful possibility of a whimsical environmental ballet, with variables dancing in statistical harmony. As we wrap up this statistical sojourn, we envision future researchers delving into the profoundly poetic interplay of environmental phenomena, perhaps stumbling upon more quirky statistical surprises and "bright" ideas. In the spirit of scientific jest, we assert that the correlation between air pollution in Milwaukee and kerosene usage in Peru has been thoroughly "lit up" by our study, and we confidently declare, in the wise words of the great statistical bard William Shakespeare, "All's well that ends well." With that, we boldly propose that no further research on this particular connection is needed, for we have shone a spark of statistical enlightenment on this peculiar pairing. Now, let's turn the "light" on other mysteries awaiting their statistical moment in the sun!


Model: gpt-3.5-turbo-1106
System prompt: You provide fictional names of academic journals. You say nothing else, and you do not chat with the user.
User prompt: Please provide the name of a funny but plausible sounding research, scientific, or academic journal that would publish a paper entited Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll. Respond only with the name of a fictional academic journal.

ChatGPT:

The Journal of Eclectic Environmental Analytics


Model: gpt-3.5-turbo-1106
System prompt: You provide fictional names of nonprofit research organizations and associations. You say nothing else, and you do not chat with the user.
User prompt: Please provide the name of a funny but plausible sounding nonprofit, academic, or scientific association or organization that would sponsor research that resulted in a paper entited Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll. Respond only with the name of a fictional organization.

ChatGPT:

The Society for the Advancement of Environmental Epidemiology


Model: gpt-3.5-turbo-1106
System prompt: You provide potential search keywords separated by commas. You say nothing else, and you do not chat with the user.
User prompt: Please provide potential search keywords for a paper titled Dependence between Air Pollution in Milwaukee and Kerosene – A Statistical Stroll with an abstract of This research is not just blowing smoke! We present findings on the unexpected but statistically significant connection between air pollution in Milwaukee and kerosene usage in Peru. Leveraging data from the Environmental Protection Agency and the Energy Information Administration, our research team conducted a thorough analysis from 1980 to 2021, revealing a correlation coefficient of 0.7945856 and a p-value of less than 0.01. The results shed light on an intriguing relationship that had previously been overlooked. This study illuminates the importance of considering global factors and thinking outside the pollution-filled box when examining regional environmental issues. So, next time you're debating whether to switch to kerosene lamps, remember that your decision might just reach all the way to Milwaukee!

ChatGPT:

Air pollution, Milwaukee, kerosene usage, correlation coefficient, p-value, environmental protection agency, energy information administration, global factors, regional environmental issues, kerosene lamps, statistical analysis

*There is a bunch of Python happening behind the scenes to turn this prompt sequence into a PDF.



Random correlation

Discover a new correlation

View all correlations

View all research papers

Report an error


Data details

Air pollution in Milwaukee
Detailed data title: Percentage of days with air quality at 'unhealthy for sensitive groups' or worse in Milwaukee-Waukesha-West Allis, WI
Source: Environmental Protection Agency
See what else correlates with Air pollution in Milwaukee

Kerosene used in Peru
Detailed data title: Volume of kerosene used consumed in Peru in millions of barrels per day
Source: Energy Information Administration
See what else correlates with Kerosene used in Peru

Correlation r = 0.7945856 (Pearson correlation coefficient)
Correlation is a measure of how much the variables move together. If it is 0.99, when one goes up the other goes up. If it is 0.02, the connection is very weak or non-existent. If it is -0.99, then when one goes up the other goes down. If it is 1.00, you probably messed up your correlation function.

r2 = 0.6313662 (Coefficient of determination)
This means 63.1% of the change in the one variable (i.e., Kerosene used in Peru) is predictable based on the change in the other (i.e., Air pollution in Milwaukee) over the 42 years from 1980 through 2021.

p < 0.01, which is statistically significant(Null hypothesis significance test)
The p-value is 3.3E-10. 0.0000000003342776175055752400
The p-value is a measure of how probable it is that we would randomly find a result this extreme. More specifically the p-value is a measure of how probable it is that we would randomly find a result this extreme if we had only tested one pair of variables one time.

But I am a p-villain. I absolutely did not test only one pair of variables one time. I correlated hundreds of millions of pairs of variables. I threw boatloads of data into an industrial-sized blender to find this correlation.

Who is going to stop me? p-value reporting doesn't require me to report how many calculations I had to go through in order to find a low p-value!
On average, you will find a correaltion as strong as 0.79 in 3.3E-8% of random cases. Said differently, if you correlated 2,991,525,450 random variables You don't actually need 2 billion variables to find a correlation like this one. I don't have that many variables in my database. You can also correlate variables that are not independent. I do this a lot.

p-value calculations are useful for understanding the probability of a result happening by chance. They are most useful when used to highlight the risk of a fluke outcome. For example, if you calculate a p-value of 0.30, the risk that the result is a fluke is high. It is good to know that! But there are lots of ways to get a p-value of less than 0.01, as evidenced by this project.

In this particular case, the values are so extreme as to be meaningless. That's why no one reports p-values with specificity after they drop below 0.01.

Just to be clear: I'm being completely transparent about the calculations. There is no math trickery. This is just how statistics shakes out when you calculate hundreds of millions of random correlations.
with the same 41 degrees of freedom, Degrees of freedom is a measure of how many free components we are testing. In this case it is 41 because we have two variables measured over a period of 42 years. It's just the number of years minus ( the number of variables minus one ), which in this case simplifies to the number of years minus one.
you would randomly expect to find a correlation as strong as this one.

[ 0.65, 0.88 ] 95% correlation confidence interval (using the Fisher z-transformation)
The confidence interval is an estimate the range of the value of the correlation coefficient, using the correlation itself as an input. The values are meant to be the low and high end of the correlation coefficient with 95% confidence.

This one is a bit more complciated than the other calculations, but I include it because many people have been pushing for confidence intervals instead of p-value calculations (for example: NEJM. However, if you are dredging data, you can reliably find yourself in the 5%. That's my goal!


All values for the years included above: If I were being very sneaky, I could trim years from the beginning or end of the datasets to increase the correlation on some pairs of variables. I don't do that because there are already plenty of correlations in my database without monkeying with the years.

Still, sometimes one of the variables has more years of data available than the other. This page only shows the overlapping years. To see all the years, click on "See what else correlates with..." link above.
198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021
Air pollution in Milwaukee (Bad air quality days)10.382510.893910.13713.77419.289629.863018.4931512.602717.486312.32887.6712313.97266.010934.383566.301379.04114.644815.205488.4931513.15074.6448110.41110.1377.945214.3715811.23293.287676.02741.639342.739733.835623.01378.743171.095892.465751.369862.459022.191782.465750.8219181.912573.28767
Kerosene used in Peru (Million Barrels/Day)18.608219.167919.02817.34917.768817.4891922221816156.91513141414141414.044914.888214.951710.80086.842954.426221.778961.164790.971531.524821.418931.397751.034891.143621.24951110.7821370.4127950.06517810.04345210.0434521




Why this works

  1. Data dredging: I have 25,153 variables in my database. I compare all these variables against each other to find ones that randomly match up. That's 632,673,409 correlation calculations! This is called “data dredging.” Instead of starting with a hypothesis and testing it, I instead abused the data to see what correlations shake out. It’s a dangerous way to go about analysis, because any sufficiently large dataset will yield strong correlations completely at random.
  2. Lack of causal connection: There is probably Because these pages are automatically generated, it's possible that the two variables you are viewing are in fact causually related. I take steps to prevent the obvious ones from showing on the site (I don't let data about the weather in one city correlate with the weather in a neighboring city, for example), but sometimes they still pop up. If they are related, cool! You found a loophole.
    no direct connection between these variables, despite what the AI says above. This is exacerbated by the fact that I used "Years" as the base variable. Lots of things happen in a year that are not related to each other! Most studies would use something like "one person" in stead of "one year" to be the "thing" studied.
  3. Observations not independent: For many variables, sequential years are not independent of each other. If a population of people is continuously doing something every day, there is no reason to think they would suddenly change how they are doing that thing on January 1. A simple Personally I don't find any p-value calculation to be 'simple,' but you know what I mean.
    p-value calculation does not take this into account, so mathematically it appears less probable than it really is.




Try it yourself

You can calculate the values on this page on your own! Try running the Python code to see the calculation results. Step 1: Download and install Python on your computer.

Step 2: Open a plaintext editor like Notepad and paste the code below into it.

Step 3: Save the file as "calculate_correlation.py" in a place you will remember, like your desktop. Copy the file location to your clipboard. On Windows, you can right-click the file and click "Properties," and then copy what comes after "Location:" As an example, on my computer the location is "C:\Users\tyler\Desktop"

Step 4: Open a command line window. For example, by pressing start and typing "cmd" and them pressing enter.

Step 5: Install the required modules by typing "pip install numpy", then pressing enter, then typing "pip install scipy", then pressing enter.

Step 6: Navigate to the location where you saved the Python file by using the "cd" command. For example, I would type "cd C:\Users\tyler\Desktop" and push enter.

Step 7: Run the Python script by typing "python calculate_correlation.py"

If you run into any issues, I suggest asking ChatGPT to walk you through installing Python and running the code below on your system. Try this question:

"Walk me through installing Python on my computer to run a script that uses scipy and numpy. Go step-by-step and ask me to confirm before moving on. Start by asking me questions about my operating system so that you know how to proceed. Assume I want the simplest installation with the latest version of Python and that I do not currently have any of the necessary elements installed. Remember to only give me one step per response and confirm I have done it before proceeding."


# These modules make it easier to perform the calculation
import numpy as np
from scipy import stats

# We'll define a function that we can call to return the correlation calculations
def calculate_correlation(array1, array2):

    # Calculate Pearson correlation coefficient and p-value
    correlation, p_value = stats.pearsonr(array1, array2)

    # Calculate R-squared as the square of the correlation coefficient
    r_squared = correlation**2

    return correlation, r_squared, p_value

# These are the arrays for the variables shown on this page, but you can modify them to be any two sets of numbers
array_1 = np.array([10.3825,10.8939,10.137,13.7741,9.28962,9.86301,8.49315,12.6027,17.4863,12.3288,7.67123,13.9726,6.01093,4.38356,6.30137,9.0411,4.64481,5.20548,8.49315,13.1507,4.64481,10.411,10.137,7.94521,4.37158,11.2329,3.28767,6.0274,1.63934,2.73973,3.83562,3.0137,8.74317,1.09589,2.46575,1.36986,2.45902,2.19178,2.46575,0.821918,1.91257,3.28767,])
array_2 = np.array([18.6082,19.1679,19.028,17.349,17.7688,17.489,19,22,22,18,16,15,6.9,15,13,14,14,14,14,14,14.0449,14.8882,14.9517,10.8008,6.84295,4.42622,1.77896,1.16479,0.97153,1.52482,1.41893,1.39775,1.03489,1.14362,1.24951,1,1,0.782137,0.412795,0.0651781,0.0434521,0.0434521,])
array_1_name = "Air pollution in Milwaukee"
array_2_name = "Kerosene used in Peru"

# Perform the calculation
print(f"Calculating the correlation between {array_1_name} and {array_2_name}...")
correlation, r_squared, p_value = calculate_correlation(array_1, array_2)

# Print the results
print("Correlation Coefficient:", correlation)
print("R-squared:", r_squared)
print("P-value:", p_value)



Reuseable content

You may re-use the images on this page for any purpose, even commercial purposes, without asking for permission. The only requirement is that you attribute Tyler Vigen. Attribution can take many different forms. If you leave the "tylervigen.com" link in the image, that satisfies it just fine. If you remove it and move it to a footnote, that's fine too. You can also just write "Charts courtesy of Tyler Vigen" at the bottom of an article.

You do not need to attribute "the spurious correlations website," and you don't even need to link here if you don't want to. I don't gain anything from pageviews. There are no ads on this site, there is nothing for sale, and I am not for hire.

For the record, I am just one person. Tyler Vigen, he/him/his. I do have degrees, but they should not go after my name unless you want to annoy my wife. If that is your goal, then go ahead and cite me as "Tyler Vigen, A.A. A.A.S. B.A. J.D." Otherwise it is just "Tyler Vigen."

When spoken, my last name is pronounced "vegan," like I don't eat meat.

Full license details.
For more on re-use permissions, or to get a signed release form, see tylervigen.com/permission.

Download images for these variables:


View another random correlation

How fun was this correlation?

You're a rater extraordinaire!


Correlation ID: 3515 · Black Variable ID: 20901 · Red Variable ID: 24811
about · subscribe · emailme@tylervigen.com · twitter

CC BY 4.0