Skip to main content Skip to main navigation

Publication

Kriging prior regression: A case for kriging-based spatial features with TabPFN in soil mapping

Jonas Schmidinger; Viacheslav Barkov; Sebastian Vogel; Martin Atzmueller; Gerard B.M. Heuvelink
In: Computers and Electronics in Agriculture, Vol. 243, Pages 1-17, Elsevier, 2026.

Abstract

Machine learning and geostatistics are two fundamentally different frameworks for the prediction and spatial mapping of soil properties. Geostatistics leverages the spatial structure of soil properties, whereas machine learning models capture the relationship between available environmental features and soil properties. We propose a hybrid framework that augments machine learning with spatial context through the engineering of ‘spatial lag’ features derived from ordinary kriging. We call this approach ‘kriging prior regression’ (KpR), as it reverses the logic of regression kriging by incorperating kriging outputs before and during the regression step. To evaluate this approach, we assessed both the point and probabilistic prediction performance of KpR, using TabPFN across six field-scale datasets from LimeSoDa. These datasets included soil organic carbon, clay content, and pH, along with features derived from remote sensing and in-situ proximal soil sensing. KpR with TabPFN demonstrated reliable uncertainty estimates and accurate predictions in comparison to several other spatial techniques (e.g., regression/residual kriging with TabPFN), as well as to established non-spatial machine learning algorithms (e.g., random forest and categorical boosting). Most notably, it improved the average R2 by ≈30% relative to machine learning algorithms without spatial context. This improvement was due to the strong prediction performance of the TabPFN algorithm itself and the complementary spatial information provided by KpR features. TabPFN is particularly effective for prediction tasks with small sample sizes, common in precision agriculture, whereas KpR can compensate for weak relationships between sensing features and soil properties when proximal soil sensing data are limited. We conclude that KpR with TabPFN is a robust and versatile modelling framework for digital soil mapping in precision agriculture.

More links