Prediction of slaughter age in pigs and assessment of the predictive value of phenotypic and genetic information using random forest

Ahmad Alsahaf*, George Azzopardi, Bart Ducro, Egiel Hanenberg, Roel Veerkamp, Nicolai Petkov

*Corresponding author for this work

Research output: Contribution to journalArticleAcademicpeer-review

11 Citations (Scopus)
42 Downloads (Pure)


The weight of a pig and the rate of its growth are key elements in pig production. In particular, predicting future growth is extremely useful, since it can help in determining feed costs, pen space requirements, and the age at which a pig reaches a desired slaughter weight. However, making these predictions is challenging, due to the natural variation in how individual pigs grow, and the different causes of this variation. In this paper, we used machine learning, namely random forest (RF) regression, for predicting the age at which the slaughter weight of 120 kg is reached. Additionally, we used the variable importance score from RF to quantify the importance of different types of input data for that prediction. Data of 32,979 purebred Large White pigs were provided by Topigs Norsvin, consisting of phenotypic data, estimated breeding values (EBVs), along with pedigree and pedigree-genetic relationships. Moreover, we presented a 2-step data reduction procedure, based on random projections (RPs) and principal component analysis (PCA), to extract features from the pedigree and genetic similarity matrices for use as inputs in the prediction models. Our results showed that relevant phenotypic features were the most effective in predicting the output (age at 120 kg), explaining approximately 62% of its variance (i.e., R2 = 0.62). Estimated breeding value, pedigree, or pedigree-genetic features interchangeably explain 2% of additional variance when added to the phenotypic features, while explaining, respectively, 38%, 39%, and 34% of the variance when used separately.
Original languageEnglish
Article numbersky359
Pages (from-to)4935-4943
Number of pages9
JournalJournal of Animal Science
Issue number12
Early online date18-Sept-2018
Publication statusPublished - Dec-2018


  • breeding
  • grouping strategies
  • machine learning
  • pigs
  • random forest
  • regression

Cite this