A stable variable selection method based on SDDSI-SPA for temperature calibration of Vis-NIR spectroscopy in water pH monitoring
Abstract
Temperature instability has a negative effect on the determination of water quality via visible-near infrared (Vis-NIR) spectroscopy, leading to non-uniform mapping relationships in cross-temperature spectral responses. However, conventional spectral correction algorithms struggle to effectively resolve temperature-induced spectral shift mechanisms, often resulting in the reduced prediction accuracy of water pH models due to variable over-correction. Thus, to address this issue, this study proposes a novel joint variable selection method termed SDDSI-SPA, which integrates the standard deviation of the difference spectra between primary and secondary instruments (SDDSI) and the successive projection algorithm (SPA). This approach effectively extracts temperature-stable, low-collinearity spectral features strongly correlated with pH values, significantly enhancing the correction efficiency of spectral calibration algorithms. Two spectral correction algorithms, direct standardization (DS) and piecewise direct standardization (PDS), were employed to resolve temperature-induced spectral variations. Five spectral datasets were collected under gradient temperature-controlled conditions (20–60 °C, ΔT = 10 °C) to validate the stability of the selected variables. Results demonstrate that the SDDSI-SPA method combined with PDS achieves stable cross-temperature spectral correction while reducing variable dimensionality, outperforming the whole-wavelength (WW), whole-wavelength combined with SPA (WW-SPA), and SDDSI-based models; the corresponding root mean square errors of prediction (RMSEP) for the 30–60 °C spectra were 0.624, 0.522, 0.562, and 0.483, respectively. Thus, this study provides a valuable reference for rapid pH assessment in water quality monitoring under complex temperature conditions.