Königsweg 65
Haus 27
14163 Berlin
+49 30 838 62618
fortpflanzungsklinik@vetmed.fu-berlin.de
The periparturient period is a physiological challenge with a high risk of subclinical hyperketonemia (SCK). We aimed to develop a machine
learning algorithm to predict SCK in transition dairy cows using an automated activity monitor (AAM). Behavioral data (active, inactive, eating,
rumination) were recorded minutely for 5,090 Holstein cows using an AAM (Smarttag Neck) for 35 d precalving. Cows were monitored for
SCK at 8 DIM using a ketone meter. Cows with BHB ≥ 1.2 mmol/L were diagnosed with SCK and treated with 250 mL of propylene glycol for
5 d. Health disorders, including retained placenta, metritis, milk fever, mastitis, or displaced abomasum within 30 DIM, were recorded. Cows
were classified into 2 groups: healthy (HLT, n = 3,471) with no SCK or other health issues and cows with SCK with no other health problems
within 30 DIM (n = 1,619). A random forest algorithm was developed using AAM behaviors as feature variables, with health status (HLT vs.
SCK) as the target variable. Individual models were trained and tested for each time point (35, 28, 21, 14, 7, and 0 d before calving). To train
the algorithm, 70% of the cows were randomly selected, while the remaining were used to evaluate predictive performance. The algorithm
consisted of 1,001 trees with 2 randomly selected variables per tree and employed 5-fold cross-validation with 5 repetitions. Feature importance
was calculated to assess each variable’s contribution to the prediction. Predictive performance was evaluated based on accuracy, specificity,
and sensitivity. The algorithm predicting HLT vs. SCK achieved high accuracy (91.43%–93.15%) and sensitivity (96.67%–97.79%) across all
time points. Specificity ranged from 69.29% to 76.19%. Rumination, eating, and inactivity were the most important predictors, particularly
at 14 d precalving, when algorithm performance was highest (93.15% accuracy, 76.19% specificity). Behavioral monitoring during the tran-
sition period could help predict SCK, supporting timely decisions to improve cow health, welfare, and farm efficiency.