China Animal Husbandry and Veterinary Medicine ›› 2022, Vol. 49 ›› Issue (7): 2534-2546.doi: 10.16431/j.cnki.1671-7236.2022.07.011

• Nutrition and Feed • Previous Articles     Next Articles

Study on Dairy Cow Disease Prediction Model Based on Machine Learning Algorithm

LI Shangru, SONG Jiamei, ZHANG Chengrui, SUN Yukun, ZHANG Yonggen   

  1. College of Animal Science and Technology, Northeast Agricultural University, Harbin 150030, China
  • Received:2021-11-20 Online:2022-07-05 Published:2022-06-29

Abstract: 【Objective】 This study was aimed to evaluate 6 kind of machine learning (ML) algorithms which were used to establish a dairy cow disease prediction model, and the importance of predictors. 【Method】 The production information,behavior information and disease information of a total of 944 lactating cows from December 2020 to November 2021 were selected as predictors to train and validated the models.Daily milk production,rumination,activity,parity,and lactation days were used as input variables,machine learning algorithms were used to establish a dairy cow disease prediction model,6 machine learning algorithms including Decision Tree (DT) C5.0,CHAID algorithm,Artificial Neural Network (ANN),Random Forests (RF),Bayesian Networks (BN) and Logistic Regression (LR) were evaluated,the importance of predictors and the improvement of model performance by including parity and lactation days were assessed as predictors.Sensitivity and specificity were used to evaluate the performance of the models,and the importance of input variables for models predictions was evaluated according to the weight ranking.【Result】 The sensitivity of DT C5.0 algorithm was greater than 85%,and the specificity was greater than 90%,which was the model with the best performance.The total sensitivity of RF was 56.8%,and the prediction performance for various types of coe was relatively stable.ANN,BN and DT CHAID had better prediction performance for diseases with a large sample size,up to 74.4%.The correct identification rate of LR for sick cow was less than 40.0%,and most of them were identified as healthy cattle.The sum of daily milk production was the most important predictor of RF,ANN,and LR,and the number of days of lactation was the most important predictor of DT C5.0,CHAID and BN.After adding parity and lactation days,the sensitivity of the model's prediction was significantly improved.【Conclusion】 Using machine learning algorithms to predict dairy cow diseases has shown potential,and among them,DT C5.0 was a more suitable model.What's more,milk production and lactation days were relatively important variables in disease prediction models.In addition,including parity and lactation days as predictors could improve the accuracy of model prediction.

Key words: dairy cow; machine learning; disease prediction

CLC Number: