DEV Community

Tasnem Islam Prome
Tasnem Islam Prome

Posted on

Analysing 68 Years of Atmospheric CO Data with Python

Tags: #python #datascience #climatechange #dataanalytics

One of the most interesting things about data analysis is the opportunity to explore real scientific questions.

For my Keeling Curve Climate Data Analysis project, I worked with historical atmospheric carbon dioxide measurements and global temperature data.

What Is the Keeling Curve?

The Keeling Curve records the long-term increase in atmospheric carbon dioxide concentrations, using measurements that began at Mauna Loa in 1958.

The project explores data from March 1958 through May 2026, alongside global temperature anomaly data.

Project Objectives

I wanted to investigate:

  • How atmospheric CO₂ concentrations changed over time
  • Whether the average growth rate increased
  • How seasonal patterns appear in the data
  • How CO₂ and global temperature trends compare
  • How to communicate scientific findings through visualisations

Tools and Data

The project uses Python, Pandas, NumPy, Matplotlib and Jupyter Notebook.

Its documented data sources include NOAA atmospheric CO₂ measurements and NASA GISS temperature anomaly data.

Key Findings

The repository reports:

Measure Result
CO₂, March 1958 315.7 ppm
CO₂, May 2026 432.3 ppm
Total increase 116.6 ppm
Percentage increase 36.9%
1960s annual growth 0.86 ppm/year
2020s annual growth 2.67 ppm/year

The analysis also reports a correlation of r = 0.966 between overlapping CO₂ and temperature time series.

This correlation should be interpreted carefully. Two strongly trending series can produce a high correlation, and correlation alone does not establish causation.

A Data-Quality Challenge

One interesting challenge involved the imported CO₂ dataset.

The expected column structure did not match the retrieved data fields.

Instead of immediately analysing the imported table, the project involved inspecting the structure, correcting column mappings and validating the results.

This reinforced an important lesson:

Never assume that imported data is analysis-ready.

Limitations

Mauna Loa is a monitoring location, not a direct measurement of every location on Earth.

The comparison also uses different observational datasets with their own measurement and modelling assumptions.

Further analysis could examine detrended relationships, uncertainty and seasonal adjustment.

Conclusion

This project helped me practise time-series analysis, data validation and scientific visualisation using real environmental data.

GitHub: https://github.com/tasnem-tech/keeling-curve-climate-data-analysis

What scientific dataset would you recommend for a future Python analysis project?

Top comments (0)