Generated by summarytools 1.1.4 (R version 4.5.1) 2025-11-09
Causal diagram (directed acyclic graph)
This diagram demonstrates that adjusting for IgG dose group will correct for the unequal IgG doses administered to Holstein and Angus X calves, due to having 2 dose randomization periods in the clinical trial that these data are collected from (details of trial reported in a separate study).
Adjusting for calf sex will remove the potential indirect effect of breed on serum IgG mediated via the higher prevalence of male calves in the Angus X group.
The causal effects of interest were:
Effect of calf breed on Serum IgG concentration
Effect of calf breed on Serum total solids
Descriptive stats
Show the code
data <- data %>%filter(!is.na(igg) &!is.na(sts_grams_l)) %>%mutate(dose =case_when( tx_group =="200g"~200, tx_group =="250g"~250, tx_group =="300g"~300, tx_group =="350g"~350 ) )table1(~ tx_group + dose + time_to_feed + vol + sex |factor(breed), data=data)
Angus x Holstein (N=119)
Holstein (N=272)
Overall (N=391)
tx_group
200g
21 (17.6%)
24 (8.8%)
45 (11.5%)
250g
35 (29.4%)
88 (32.4%)
123 (31.5%)
300g
39 (32.8%)
79 (29.0%)
118 (30.2%)
350g
24 (20.2%)
81 (29.8%)
105 (26.9%)
dose
Mean (SD)
278 (50.3)
290 (48.4)
286 (49.2)
Median [Min, Max]
300 [200, 350]
300 [200, 350]
300 [200, 350]
time_to_feed
Mean (SD)
57.3 (28.9)
60.7 (29.9)
59.7 (29.6)
Median [Min, Max]
50.0 [0, 190]
50.0 [0, 195]
50.0 [0, 195]
vol
Mean (SD)
3.02 (0.591)
3.10 (0.538)
3.08 (0.555)
Median [Min, Max]
3.10 [1.80, 3.90]
3.10 [1.80, 3.90]
3.10 [1.80, 3.90]
sex
F
60 (50.4%)
255 (93.8%)
315 (80.6%)
M
59 (49.6%)
17 (6.3%)
76 (19.4%)
Show the code
# Coerce to analysis-friendly typesdata_tbl <- data %>%mutate(breed =factor(breed),sex =factor(sex),# If time_to_feed is hms/difftime/character, coerce to numeric minutes:time_to_feed =as.numeric(time_to_feed) # adjust if already in minutes# If it's a string like "01:23:45", do:# time_to_feed = as.numeric(hms::as_hms(time_to_feed)) / 60 )data_tbl %>%select(breed, dose, time_to_feed, vol, sex) %>%tbl_summary(by = breed,type =list(sex ~"categorical"),statistic =list(all_continuous() ~"{median} [{p25}, {p75}]",all_categorical() ~"{n} ({p}%)" ),digits =all_continuous() ~1,missing ="no" ) %>%add_p(test =list(all_continuous() ~"kruskal.test", # safe for non-normal dataall_categorical() ~"chisq.test" ) ) %>%bold_labels()
Characteristic
Angus x Holstein
N = 1191
Holstein
N = 2721
p-value2
dose
0.029
200
21 (18%)
24 (8.8%)
250
35 (29%)
88 (32%)
300
39 (33%)
79 (29%)
350
24 (20%)
81 (30%)
time_to_feed
50.0 [35.0, 70.0]
50.0 [40.0, 75.0]
0.4
vol
3.1 [2.5, 3.6]
3.1 [2.7, 3.5]
0.2
sex
<0.001
F
60 (50%)
255 (94%)
M
59 (50%)
17 (6.3%)
1 n (%); Median [Q1, Q3]
2 Pearson’s Chi-squared test; Kruskal-Wallis rank sum test
ROC curve for Angus X to assess the performance of STS to predict IgG >25 g/L.
5.9 g/dl STS has a sensitivity of 58% and specificity of 95%.
This cut-off shows similar performance to the current established threshold of 6.2g/dl for Holsteins. However, this is an interim recommendation only as there is not enough data to make this conclusion and more research required to verify this.
5.6 g/dl STS has a sensitivity of 77% and specificity of 67%.
AUC is 0.85.
Conclusion:
STS is a good test for predicting serum IgG of >25g/L as the area under the curve is high 0.85.
STS test for estimating serum IgG perform equivalently for both breeds as the AUC is the same.
A lower cutpoint may be necessary for predicting Angus X animals with serum IgG >25g/L. However, further research is required to confirm what value cut-off should be used.
Comparing the use of a STS cut-point of 62g/L to predict if a calf has IgG > 25g/L