A Streamlit air-quality monitoring dashboard for Secunda, South Africa.
# Secunda Air Watch 🌍
A Streamlit-based air-quality monitoring dashboard for **Secunda, Mpumalanga, South Africa**.
Secunda Air Watch collects air-quality data from the Open-Meteo Air Quality API, processes the data using Python, calculates South African Air Quality Index (SA AQI) bands, stores historical records in a SQLite database, and presents the results through an interactive dashboard.
## 📊 Project Overview
The purpose of this project is to provide a simple way to monitor air-quality conditions in Secunda and analyse pollutant levels over time.
The dashboard focuses on pollutants including:
* PM2.5
* PM10
* Carbon Monoxide (CO)
* Nitrogen Dioxide (NO₂)
* Sulphur Dioxide (SO₂)
* Ozone (O₃)
The project uses **South African AQI bands as the primary air-quality assessment**, while US AQI is also displayed as a secondary reference.
## ✨ Features
* 🌍 Air-quality monitoring for Secunda
* 📊 Current pollutant measurements
* 🇿🇦 South African AQI band calculations
* 🔎 Identification of the main pollutant
* 📈 Interactive air-quality trends
* 🗄️ SQLite database for storing air-quality records
* 📊 SQL-based data analysis
* 📅 Daily air-quality summaries
* 🚨 Identification of the worst air-quality day
* 📥 CSV data export
* 📊 Excel report export
* 🔄 Forecast analysis for different time ranges
## 🗄️ SQL & Database
The project uses **SQLite** to store air-quality records.
The database stores information such as:
* Timestamp
* PM2.5
* PM10
* Carbon Monoxide
* Nitrogen Dioxide
* Sulphur Dioxide
* Ozone
* US AQI
* South African AQI band
* Dominant pollutant
SQL queries are used to calculate averages, group AQI bands, and generate daily air-quality summaries.
## 🇿🇦 South African AQI Analysis
The project calculates South African AQI bands for individual pollutants and determines the overall air-quality band based on the highest pollutant band.
The dashboard also identifies the pollutant contributing most significantly to the current overall AQI band.
## 🛠️ Technolo …