JOURNAL ARTICLE

Heavy metal content prediction based on Random Forest and Sparrow Search Algorithm

Abstract

Abstract X‐ray fluorescence (XRF) analysis is exceedingly suitable for detecting heavy metal contents in soil. In order to do that, an accurate prediction model based on XRF analysis is necessary. But in practice, the XRF spectral data is susceptible to moisture content in soil, which may lead to inaccurate prediction results. Accordingly, a new prediction model based on Random Forest Regression (RFR) and improved Sparrow Search Algorithm (SSA) was proposed, which takes the variation of moisture content into consideration. At first, the XRF spectral data were obtained by experiment. Owing to the advantages of training speed and prediction ability, the RFR was employed to predict the heavy metal contents. In order to further improve the performance of RFR, the SSA was selected and improved with theory of good‐point set, which can determine optimum hyper‐parameters of RFR conveniently. It can be found by comparison that the proposed model outperforms other commonly used models.

Keywords:
Random forest Content (measure theory) Water content Sparrow Set (abstract data type) Algorithm Computer science Point (geometry) Soil science Mathematics Environmental science Machine learning Engineering Ecology

Metrics

15
Cited By
2.05
FWCI (Field Weighted Citation Impact)
30
Refs
0.81
Citation Normalized Percentile
Is in top 1%
Is in top 10%

Citation History

Topics

Spectroscopy and Chemometric Analyses
Physical Sciences →  Chemistry →  Analytical Chemistry
Mineral Processing and Grinding
Physical Sciences →  Engineering →  Mechanical Engineering
Image Processing and 3D Reconstruction
Physical Sciences →  Computer Science →  Computer Vision and Pattern Recognition
© 2026 ScienceGate Book Chapters — All rights reserved.