Machine learning / Forecasting
Benchmarking US maize yield forecasts
Can weather observed through July improve on a county’s own yield trend in future harvest years?
Solution
I used weather and soil data to compare tree models with county trends, then tested the forecasts on later harvests.
My contribution · I joined county weather and soil records, built the trend baseline, and held out later years for the final model comparison.
Tools Python · XGBoost · scikit-learn · FastAPI
Results
Across 1,391 held-out county-years, the trend baseline had lower RMSE than XGBoost: 26.79 bu/acre versus 33.21 bu/acre.
All candidates had negative R² on the 2016–2018 test.
- County trend holdout RMSE
- 26.79 bu/acre Source
Data & evaluation
Data sources
- Paudel, de Wit and Boogaard US county maize data, 2000–2018
Method
- Reserve 2014–2015 for selection and 2016–2018 for the final test. Restrict weather inputs to April through July.
- Build county-year weather and soil features, fit baselines and tree models, and retain the validation-selected model when reporting the future-year ranking.
Limitations
The same counties recur across years. The comparison covers only three final test years and county-level yields.
Testing transfer requires holding out entire counties. Farm-level performance requires a separate farm-level dataset.
Reproduce the study
Use Python 3.12 and the locked requirements. Rebuild the county-year inputs, then run the documented baseline and model evaluation.
Local reproduction instructions and pinned sourceSkills demonstrated
- Time-aware validation
- Feature engineering
- Baseline comparison
Project figures

Validation contained 2014–2015 data. On the 2016–2018 holdout, the county trend had lower error than the selected XGBoost model.
Idriss Lemnouni. Data by D. Paudel, A. de Wit and H. Boogaard (CC BY 4.0).Figure source
The selected model reached 33.21 bu/acre test RMSE, and all reported models had negative test R².
Idriss Lemnouni. Data by D. Paudel, A. de Wit and H. Boogaard (CC BY 4.0).Figure source