Nature Communications

Modeling nonlinear and interaction effects of spatiotemporal and nongenetic factors improves prediction for complex traits

2026-08-29

Adjusting for nongenetic factors improves genetic association testing and polygenic scores, yet most studies rely on linear adjustments for limited covariate sets. Location and time covariates can proxy environmental exposures but are rarely included, and linear adjustments cannot capture their nonlinear effects or interactions. We adopt a null model approach where an auxiliary nonlinear model predicts phenotypes from covariates alone. This prediction is then included as an additional covariate in downstream analysis. Using 16 phenotypes in the UK Biobank, we show gradient boosted decision tree nulls including spatiotemporal features improve covariate modeling. Incorporating these nonlinear spatiotemporal covariate predictions improves polygenic prediction for all phenotypes (median 7.3% R 2 gain with BASIL). Model interpretation reveals covariate interactions including sex-specific age effects, seasonal patterns, and complex geospatial dependencies. Together, these results demonstrate that a small addition to existing polygenic score workflows can improve predictions and provide insights into environmental effects for complex traits.

Full text

DOI https://doi.org/10.1038/s41467-026-76154-7