Interpreting Machine Learning Models with SHAP Values: Application to Crude Protein Prediction in Tamani Grass Pastures

Machine learning models such as XGBoost show strong potential for predicting pasture quality metrics like crude protein (CP) content in tamani grass (Panicum maximum). However, their ‘black box’ nature hinders practical adoption. To address this limitation, this study applied SHapley Additive exPlanations (SHAP) to interpret an XGBoost model and uncover how management practices (grazing interval, nitrogen fertilization, and pre- and post-grazing heights) and environmental factors (precipitation, temperature, and solar radiation) jointly influence CP predictions. Data were divided into 80% for training/validation and 20% for testing. Model performance was assessed with stratified 5-fold cross-validation, and hyperparameters were tuned via grid search. The XGBoost model yielded a Pearson correlation coefficient (r) of 0.78, a mean absolute error (MAE) of 1.45, and a coefficient of determination (R2) of 0.57. The results showed that precipitation in the range of 100–180 mm increased the predicted CP content. Application of 240 kg N ha−1 year−1 positively affected predicted CP, whereas a lower dose of 80 kg N ha−1 year−1 had a negative impact, reducing predicted levels of CP. These findings highlight the importance of integrated management strategies that combine grazing height, nitrogen fertilization, and grazing intervals to optimize crude protein levels in tamani grass pastures.

Authors

Institutions

Publication Details

Journal
Agronomy
Published
2025-12-02
DOI
https://doi.org/10.3390/agronomy15122780
Citations
1
Primary Topic
Ruminant Nutrition and Digestive Physiology
Type
article
Field-Weighted Citation Impact
1.90

Funders

Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Interpreting Machine Learning Models with SHAP Values: Application to Crude Protein Prediction in Tamani Grass Pastures

Marina Castro, Juan Campos, Marislayne de Gusmão Pereira, Gelson dos Santos Difante et al.
1 citations
Agronomy
Ruminant Nutrition and Digestive Physiology
1.90
article

Interpreting Machine Learning Models with SHAP Values: Application to Crude Protein Prediction in Tamani Grass Pastures

Marina Castro, Juan Campos, Marislayne de Gusmão Pereira, Gelson dos Santos Difante, Jéssica Gomes Rodrigues, Valéria Pacheco Batista Euclides, Luís Carlos Vinhas Ítavo, Denise Baptaglin Montagner, Anderson Bessa da Costa, Gabriela Oliveira de Aquino Monteiro, Edson Takashi Matsubara
article en
1 citations

Abstract

Machine learning models such as XGBoost show strong potential for predicting pasture quality metrics like crude protein (CP) content in tamani grass (Panicum maximum). However, their ‘black box’ nature hinders practical adoption. To address this limitation, this study applied SHapley Additive exPlanations (SHAP) to interpret an XGBoost model and uncover how management practices (grazing interval, nitrogen fertilization, and pre- and post-grazing heights) and environmental factors (precipitation, temperature, and solar radiation) jointly influence CP predictions. Data were divided into 80% for training/validation and 20% for testing. Model performance was assessed with stratified 5-fold cross-validation, and hyperparameters were tuned via grid search. The XGBoost model yielded a Pearson correlation coefficient (r) of 0.78, a mean absolute error (MAE) of 1.45, and a coefficient of determination (R2) of 0.57. The results showed that precipitation in the range of 100–180 mm increased the predicted CP content. Application of 240 kg N ha−1 year−1 positively affected predicted CP, whereas a lower dose of 80 kg N ha−1 year−1 had a negative impact, reducing predicted levels of CP. These findings highlight the importance of integrated management strategies that combine grazing height, nitrogen fertilization, and grazing intervals to optimize crude protein levels in tamani grass pastures.

AgronomyVol. 15(12)
Universidade Federal de Mato Grosso do Sul (BR), Brazilian Agricultural Research Corporation (BR), Universidade Politécnica de Bragança (PT)
Coordenação de Aperfeiçoamento de Pessoal de Nível Superior, Conselho Nacional de Desenvolvimento Científico e Tecnológico, Fundação de Apoio ao Desenvolvimento do Ensino, Ciência e Tecnologia do Estado de Mato Grosso do Sul, Universidade Federal de Mato Grosso do Sul
Openalex Percentile: Top 11%
Ruminant Nutrition and Digestive Physiology
1.90
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.