Water Quality Dataset from Water Sources in Kenya

Published: 1 April 2026| Version 1 | DOI: 10.17632/575ctg3nnr.1
Contributors:
,
,

Description

This dataset contains water quality measurements collected using an IoT-based sensing system deployed across multiple water sources in Kenya. The data was gathered over February–March 2026 at two-minute intervals, resulting in 100,800 observations. Each record includes four key physicochemical parameters: pH, Total Dissolved Solids (TDS), turbidity, and temperature, a binary classification label indicating whether the water is safe for drinking or requires treatment. The dataset covers diverse water sources, including: Treated municipal and bottled water (safe) Rivers and lakes (surface water) Borehole water (groundwater) Marine water (Indian Ocean) Preprocessing steps included handling missing values through imputation, outlier assessment based on environmental plausibility, and feature normalization. The dataset is designed for machine learning applications, particularly binary classification of water quality and real-time monitoring using IoT or edge (TinyML) systems.

Files

Steps to reproduce

Set Up the IoT Sensing System Assemble a water quality monitoring device with calibrated sensors for: pH Total Dissolved Solids (TDS) Turbidity Temperature Connect the sensors to a microcontroller (e.g., Arduino/Raspberry Pi) with data logging capability. Select Sampling Locations Identify diverse water sources to ensure variability: Treated municipal water and bottled water Rivers and lakes (surface water) Boreholes (groundwater) Marine water (if accessible) Deploy the Device Place the sensing device at each location and ensure stable positioning in the water source. Allow sensors to stabilise before recording measurements. Configure Data Collection Set the system to record readings at 2-minute intervals. Each record should include: timestamp, pH, TDS, turbidity, temperature Collect Data Over Time Conduct continuous monitoring over a defined period (e.g., several weeks). Move the device across different locations to capture environmental diversity. Label the Data Assign labels based on water source: Safe → treated municipal and bottled water Unsafe → surface water, groundwater, and marine water Aggregate the Dataset Combine all collected data into a single tabular dataset (e.g., CSV format), where each row represents one observation. Perform Data Cleaning Handle missing values using imputation Remove or correct erroneous sensor readings Retain realistic environmental variations Normalize Features (Optional) Apply feature scaling to standardise parameter ranges for machine learning use. Final Dataset Validation Verify: Consistent formatting Correct labels Reasonable parameter ranges

Institutions

Categories

Water Quality, Water Quality Assessment

Funders

  • Adventist University of Africa

Licence