Observational study on associations between resilience indicators based on daily milk yield in first lactation and lifetime profitability

Resilience is the ability of cows to be minimally affected by disturbances, such as pathogens, heat waves, and changes in feed quality, or to quickly recover. Obvious advantages of resilience are good animal welfare and easy and pleasant management for farmers. Furthermore, economic effects are also expected, but these remain to be determined. The goal of this study was to investigate the association between resilience and lifetime gross margin, using indicators of resilience calculated from fluctuations in daily milk yield using an observational study. Resilience indicators and lifetime gross margin were calculated for 1,325 cows from 21 herds. These cows were not alive anymore and, therefore, had complete lifetime data available for many traits. The resilience indicators were the natural log-transformed variance (LnVar) and the lag-1 autocorrelation (r auto ) of daily milk yield deviations from cow-specific lactation curves in parity 1. Good resilience is indicated by low LnVar (small yield response to disturbances) and low r auto (quick yield recovery to baseline). Lifetime gross margin was calculated as the sum of all revenues minus the sum of all costs throughout life. Included revenues were from milk, calf value, and slaughter of the cow. Included costs were from feed, rearing, insemination, management around calving, disease treatments, and destruction in case of death on farm. Feed intake was unknown and, therefore, lifetime feed costs had to be estimated based on milk yield records. The association of each resilience indicator with lifetime gross margin, and also with the underlying revenues and costs, was investigated using analysis of covariance (ANCOVA) models. Mean daily milk yield in first lactation, herd, and year of birth were included as covariates and factors. Natural log-transformed variance had a significantly negative association with lifetime gross margin, which means that cows with stable milk yield (low LnVar, good resilience) in parity 1 generated on average a higher lifetime gross margin than cows that had the same milk yield level but with more fluctuations. The association with lifetime gross margin could be mainly attributed to higher lifetime milk revenues for cows with low LnVar, due to a longer lifespan. Unlike LnVar, r auto was not significantly associated with lifetime gross margin or any of the underlying lifetime costs and revenues. However, it was significantly associated with yearly treatment costs, which is important for ease of management. In conclusion, the importance of resilience for total profit generated by a cow at the end of life was confirmed by the significant association of LnVar with lifetime gross margin, although effects of differences in feed efficiency between resilient and less resilient cows remain to be studied. The economic advantage can be mainly ascribed to benefits of long lifespan.


INTRODUCTION
The production environment of cows is changing, with an increasing number of cows per labor unit and more disturbances (e.g., due to climate change).In these changing environments it is important that cows can cope with disturbances well, and are therefore easy to manage (Berghof et al., 2019).The ability to be minimally affected by disturbances and to quickly recover if affected is called resilience (Colditz and Hine, 2016).
Resilience of cows and other animals, and especially quantification of resilience, has been studied extensively in recent years (e.g., van Dixhoorn et al., 2018;Putz et al., 2019;Poppe et al., 2020;van der Zande et al., 2020).Many studies quantified resilience using indicators based on fluctuations in longitudinal traits.The theory behind the use of fluctuations in longitudinal traits is that many longitudinal traits are sensitive to disturbances.Therefore, the fluctuation pattern of such longitudinal traits is indicative of the resilience of an animal (Scheffer et al., 2018).Examples of resilience indicators based on longitudinal traits in dairy cattle are the variance and the lag-1 autocorrelation (r auto ) of milk yield (Elgersma et al., 2018;Poppe et al., 2020) and activity (van Dixhoorn et al., 2018).Here, low variance and autocorrelation indicate a stable pattern over time and thus good resilience.Such resilience indicators are useful to distinguish resilient from less resilient animals.Some of these studies have investigated the use of resilience indicators in genetic selection (Elgersma et al., 2018;Poppe et al., 2020).The natural log-transformed variance (LnVar) and r auto of daily deviations from expected milk yield were heritable, and genetically associated with sensitivity of milk yield to disturbances and recovery time (Poppe et al., 2021c), and with health traits and longevity (Poppe et al., 2020(Poppe et al., , 2021a)).
Being resilient has obvious advantages for cow welfare and job satisfaction of the farmer.However, effects on cow profitability are expected as well (Berghof et al., 2019;Knap and Doeschl-Wilson, 2020).Positive effects of resilience on profitability are expected through a smaller yield loss upon disturbances (Poppe et al., 2021c) and fewer labor costs, due to fewer health problems and fewer cows with alerts generated by automated systems (Berghof et al., 2019).Positive effects are also expected through favorable associations with health, longevity, and fertility.These traits all have an effect on cow profitability, for example, through decreasing treatment costs with fewer diseases (Huijps et al., 2008;Bruijnis et al., 2010), dilution of rearing costs per kilogram of milk with increasing productive life (Rendel and Robertson, 1950;Grandl et al., 2019), and decreasing insemination costs and increasing the number of productive days in peak lactation with improved fertility (Inchaisri et al., 2010).
Negative effects of resilience on profitability are expected as well, because of a trade-off between resilience and feed efficiency, where resilient cows need more feed to produce a certain amount of milk than less resilient cows (Friggens et al., 2017;Poppe et al., 2020;Martin et al., 2021).However, feed efficiency is often considered only on a lactation level.It is important to recognize that through a positive effect of resilience on longevity, the association between resilience and feed efficiency may actually be favorable because of more milk produced per cow, which dilutes feed costs during rearing.It is, therefore, important to take costs and revenues throughout the whole lifetime into account and not only throughout the first lactation.
Nowadays, more information that can help to determine costs and revenues throughout life is becoming routinely available on commercial dairy farms.For ex-ample, with electronic milk recording on many farms, milk yield data are available on a more frequent basis than before with test-day milk yield.These daily data make it possible to determine the exact lifetime production, including all drops in milk yield due to poor resilience, instead of having to rely on an estimation based on test-day records (e.g., Strandberg, 1992;Mulder and Jansen, 2001;Pérez-Cabal and Alenda, 2003).Earlier, this type of information was mainly available on research farms.Research farms still do have an advantage over commercial farms in that they often measure feed intake (e.g., Simm et al., 1994;Hüttmann et al., 2009), whereas commercial farms do not.Still, the advantage of commercial farms is that data are available on more cows, and cows are not subjected to experiments.We believe that the amount and frequency of data on commercial farms that are available currently, despite the lack of feed intake data, provide a good opportunity to investigate the association between resilience and lifetime profitability.
In summary, many associations between resilience and costs and revenues contributing to profitability are expected, but it is still unclear what the overall effect of resilience on lifetime profit is.Investigating the effect of resilience indicators on lifetime profitability can build further support as to why resilience is important.Therefore, the aim of this study was to investigate the association of resilience indicators measured in first parity (LnVar and r auto of daily deviations from expected milk yield; Poppe et al., 2020) with the lifetime gross margin of cows, expressed as the sum of all revenues throughout life minus the sum of all costs throughout life.

MATERIALS AND METHODS
Data processing and analyses were performed using the NumPy (Harris et al., 2020), Pandas (McKinney, 2010), and Statsmodels (Seabold and Perktold, 2010) packages from Python 3.6 and 3.8.5, the AWK programming language (Aho et al., 1988), and R (R v 3.2.2;R Project for Statistical Computing).No animals were used in this study, and ethical approval for the use of animals was thus deemed unnecessary.

Data
Four data sets were used to calculate resilience indicators and lifetime gross margin for individual cows.All data sets were obtained from Cooperation CRV (Arnhem, the Netherlands).The first data set contained milk yield records obtained during single milk visits to automatic milking systems (AMS) and conventional milking systems.This data set contained 2,763,357,043 milk visit records on 1,528,030 cows in

Selection of Herds
Figure 1 shows a flow diagram of selection of herds.From all available herds, herds were selected that had data in all 4 data sets from before 2012 until at least January 1, 2020, and cows should be milked the entire period by AMS.Furthermore, herds were required to have continuous registration of milk yield in the AMS; not more than 5% of dates in the timeframe of a herd were allowed to have no milk yield records.Furthermore, only herds were selected where AI were performed by AI technicians and not by farmers to ensure appropriate quality of insemination registrations.Furthermore, herds were required to have registrations of each of the following common diseases: claw disorders, mastitis, and uterus related disorders.These diseases can be assumed to occur on every farm, and presence of a registration in a herd is a confirmation that the farmer registers diseases (registration is not mandatory in the Netherlands).The mean number of registrations per herd for herds with registrations was 1,126.48, 89.89, and 52.20, respectively.This comes down to on average approximately 3 claw disorder registrations per cow throughout life, 30% of cows having a mastitis registration throughout life, and 18% of cows having a uterus-related disorder throughout life.Appendix Table A1 shows in more detail the lifetime incidences and minimum and maximum number of registrations throughout life of these and other diseases in the final selected herds.Finally, 21 herds met all criteria.For these 21 herds, 13,896,163 AMS milk visit records on 6,164 cows were available, 175,976 milk production registration records on 6,049 cows, 46,556 insemination records on 6,150 cows, and 47,071 disease diagnosis records on 5,215 cows.

Selection of Cows
Figure 1 shows a flow diagram of selection of cows within herds.Because the aim was to calculate realized lifetime gross margin of cows, within the selected herds, cows were selected that were not alive anymore and had continuous AMS visit data in the same herd from first parity until the date of death.Death dates and death codes (slaughter or dead on farm) were available from Cooperation CRV (Arnhem, the Netherlands).Additionally, to reduce skewness in the data because cows born more recently are automatically cows that are culled early, cows were required to have had the opportunity to reach a productive life of 3 yr in the data sets.To clarify, cows were allowed to be culled before they reached a productive life of 3 yr, but time between first calving of a cow and last available milk record from the whole herd should be at least 3 yr.No restriction was set on the maximum age, and the oldest cow in the data set was culled at 10.7 yr of age.Furthermore, cows were required to be at least 87.5% Holstein Friesian, and to have calved for the first time after 640 d of age and before 1,128 d (37 mo).To be able to calculate resilience indicators following the same rules as in Poppe et al. (2020), the first milk yield record in first lactation was required to be within 2 wk after calving, and at least 50 milk yield records were required until 350 DIM, excluding the first and last 10 DIM.Finally, at least 5 cows were required to be born within the same herd in the same year, to be able to include a contemporary group effect in the analyses.Herd-birth year groups with less than 5 cows were removed.Finally, 1,325 cows were suitable for analysis, with 3,500,720 AMS records, 38,160 milk production registration records, 11,247 insemination records, and 13,145 disease records.

Data Preparation
The AMS milk visit records were first converted to daily milk yield records.Within cow, all milk yield records within a day were summed to get the total daily milk yield, but the first milking of the day was partly assigned to the previous day, depending on the proportion of the milking interval that was before midnight (G.de Jong, Cooperation CRV, Arnhem, the Netherlands, personal communication).This approach was used to remove variation in milk yield between days that was not related to resilience, but was due to chance (if the milking was just before or after midnight).This resulted in 1,283,463 daily milk yield records.Outlying daily milk yield records were removed if they deviated positively from an individually fitted Wilmink curve (Wilmink, 1987), and the deviation was larger than 6 times the standard deviation of the deviation of all cows in the same parity, year of calving, and day of lactation (CRV, 2020).Because still some high milk yield records were present that were deemed outliers based on visual inspection, milk yield records larger than 90 kg were removed as well.In total, 770 daily milk yield records were removed, resulting in 1,282,693 final daily milk yield records.

Calculation of Resilience Indicators
For all cows, resilience indicators were calculated based on daily milk yield data in first parity, using the same method as Poppe et al. (2020).First, potential daily milk yield until 350 DIM in absence of disturbances was estimated using polynomial quantile regression on the 0.7 quantile: where y t is the observed milk yield on DIM t, t n are DIM to the power of n, where n is 1, 2, 3, or 4, β n are regression coefficients describing the relationships between t n and y t , and ε is the error term.The quantreg package (Koenker, 2018) and the poly function in R were used.The 0.7 quantile causes the expected milk yield to be less influenced by low milk yield records than by high records, resulting in a lactation curve that is closer to what is expected in absence of disturbances.Deviations from the regression curve were calculated by subtracting the expected milk yield from the observed milk yield, and they represent the short-term fluctuation pattern in milk yield due to disturbances.The resilience indicators were then calculated on all deviations until 350 DIM per cow, excluding the first and last 10 deviations.The resilience indicators were the LnVar and the r auto of the daily deviations.In addition to the resilience indicators, the average daily milk yield until 350 DIM in parity 1 (ADMY) was calculated for each cow.The ADMY was needed to investigate relationships between the resilience indicators and lifetime gross margin, independent of milk yield level, because especially LnVar, but also r auto are positively associated (genetically and at herd level) with ADMY (Poppe et al., 2020(Poppe et al., , 2021a,b),b).

Calculation of Lifetime Gross Margin
To get insight into the lifetime profitability, we calculated the lifetime gross margin (LGM), as the sum of all revenues minus the sum of all costs during the lifetime of a cow: LGM = (revenues milk + revenues calves + revenues slaughter ) − (costs feed + costs rearing + costs insemination + costs calves + costs treatments + costs destruction ).
All revenues and costs taken into account in this study will be explained below.

Lifetime Revenues
The first source of lifetime revenues of each cow consisted of the sum of all revenues from milk, depending on the amount of milk, fat, protein, and lactose pro-duced.The amount of milk produced on each day for each cow was obtained from the AMS daily milk yield data set.Missing records during lactation were linearly interpolated with the interpolate method in Python.Daily fat, protein, and lactose content were linearly interpolated within lactation from the 3-to 6-wk fat, protein, and lactose content measurement in the milk production registration data set.The records before the first milk production registration within cow were assigned the fat, protein, and lactose content of the first milk production registration.The same accounts for the records after the last milk production registration, but these were assigned the fat, protein, and lactose content of the last registration.For lactations without fat, protein, and lactose records (when cow was culled before the first milk production registration in the last lactation; 2.9% of all lactations), their fat, protein, and lactose contents were assumed to be equal to the mean of all fat, protein, and lactose records in their herd in the same parity at the same date.If there were no cows with data in the same herd, parity, and date, the mean of all cows in the same herd at the same date were taken.The total milk yield, fat yield, protein yield, and lactose yield in kilograms produced throughout life were then calculated, and the lifetime milk revenues were calculated as Revenues milk = P milk × Milk + P fat × Fat + P protein × Protein + P lactose × Lactose, where P milk , P fat , P protein , and P lactose were the prices of milk and milk contents (Table 1), and Milk, Fat, Protein, and Lactose were the total amount of milk, fat, protein, and lactose calculated for the entire life (kg).
The second source of lifetime revenues was the value of all calves born from a cow.The total value of calves born per cow was calculated by multiplying the total number of calves born by the price of a calf sold at 2 wk of age (Table 1).
The third source of lifetime revenues was sale of the cow at the end of life.It was assumed that cows were sold for slaughter price (Table 1).For cows that were euthanized according to the data set with diagnoses and treatments, or that died on farm, the slaughter price was set to €0.Costs for euthanization and destruction will be described below.

Lifetime Costs
For lifetime costs, only those costs were taken into account that were expected to vary with varying resilience measures.The first source of lifetime costs was feed costs.Actual feed intake was unknown and therefore feed costs were estimated based on energy requirements using the VEM system (Dutch net energy system for lactation; CVB, 2016).Daily VEM requirements depended on milk yield, maintenance requirements, gestation stage, and growth.
Daily VEM requirements for milk yield and maintenance were calculated as (CVB, 2016) where BW is body weight (kg) and FPCM is fat-and protein-corrected milk.Because no records on BW were available, it was assumed that BW was 540 kg at the start of lactation 1, 595 kg at the start of lactation 2, and 650 kg at the start of lactation 3 (CVB, 2016), and BW increased linearly in between (Kok et al., 2017).Daily fat-and protein-corrected milk yield was calculated for each cow as follows (Blanken et al., 2020): where fat and protein were fat and protein content (%) and milk was amount of milk (kg).In addition to the daily VEM requirements for milk yield and maintenance, extra daily VEM requirements for gestation were 450, 850, 1,500, and 2,700 VEM per day in the 6, 7, 8, and 9 mo of pregnancy, respectively (CVB, 2016).Extra daily VEM requirements for growth were 660 VEM per day for cows in first parity and 330 VEM per day for cows in second parity (CVB, 2016).The total lifetime VEM requirement of each cow was then calculated by summing all daily VEM requirements throughout life.The lifetime feed costs were then calculated by multiplying lifetime VEM requirement by the VEM price (Table 1).
The second source of lifetime costs was the rearing cost, which depends on the length of the rearing period, represented by the age at first calving.An age at first calving of 25 mo was taken as a baseline based on Mohd Nor et al. ( 2012), who found an average age of calving of 25 mo in their simulation of rearing costs of Dutch heifers, with an estimated rearing cost of €1,567.For each cow, a cost was subtracted or added to €1,567 when the age at first calving was earlier or later than 25 mo.The amount of money extracted or added was €2.19 per day, based on Mohd Nor et al. ( 2012), who estimated the difference in costs between a heifer calving at 24 and 30 mo of age to be €400.
The third source of lifetime costs was insemination costs.Lifetime insemination costs of each cow were obtained by multiplying the number of inseminations in the inseminations data set with the price of an insemination by an AI technician plus average semen price (Table 1).Registered natural matings (3%) were treated as AI as well for simplicity.Inseminations before first calving were not included in the number of inseminations, because of missing records for substantial part of youngstock.
The fourth source of lifetime costs was the cost of birth of a calf and keeping it until 2 wk of age (Table 1), multiplied by the number of calvings from a cow.
The fifth source of lifetime costs was total treatment costs, consisting of disease costs and costs of euthanasia.Only diseases that occurred at least 40 times in the data set (13 diseases) were included to avoid a too broad range of diseases.Diseases with a lower occurrence (33 diseases) were rather incidental and most occurred less than 10 times or were not related to resilience (for example a bruise or a sharp object in the rumen).The costs of the selected diseases were added up for each cow throughout the entire life.If a disease was registered multiple times within the same cow within 1 wk, the costs of the disease were included only once.Appendix Table A1 in the Appendix shows the lactational incidence of each disease and the minimum and maximum number of cases throughout life for each disease.Appendix Figure A1 shows the variation in proportion of cows with at least 1 case of each disease between herds.The costs of each treatment, including labor, were obtained from a veterinarian and are summarized in Table 2.The costs of claw disorders are summarized in Table 3.For treatments with antibiotics, the price of discarded milk was included in the total treatment costs.Price of discarded milk was calculated using the amount of milk, fat, protein, and lactose produced during the treatment period and waiting period after treatment (Table 2) multiplied by the milk price formula shown earlier.
The last sources of lifetime costs were destruction and collection costs, which were assigned to cows that were euthanized or died on farm (Table 1), and otherwise set to €0.

Analyses
The association between the resilience indicators and LGM was investigated using analysis of covariance, with herd, year of birth, the interaction between herd and year of birth, and ADMY as factors and covariates.Herd and year of birth were included to adjust for effects on LGM of common management in contemporary groups and difference in opportunity period for cows born in recent years compared with less recent years.Season of birth was not included to define contemporary groups, because not enough animals per group were present (when requiring at least 5 animals per herd-year-season group, only 102 animals were left in the data set).Average daily milk yield was included to adjust for milk yield level, which was positively correlated with especially LnVar (0.23), but also r auto (0.14).To obtain a better understanding of the association between the resilience indicators and LGM, the analysis was repeated for all revenues and costs contributing to LGM, and also for all underlying traits such as herd life, lifetime milk yield, and lifetime discarded milk.Furthermore, the same analysis was performed on LGM, revenues, costs, and underlying traits expressed per year of productive life.Profit, revenues, costs, and underlying traits per productive year (y yearly ) were calculated as where y is LGM, revenues, costs, or an underlying trait and PL is productive life (d), expressed as the time between first calving and culling date.If the productive life was less than 365 d, the correction was not applied and y yearly was assumed to be y (Pérez-Cabal and Alenda, 2003).As a result, y yearly was lower for cows with a productive life shorter than 365 d than for cows with a longer productive life.To correct for this, an additional covariate was included in the models for the traits expressed per productive year.This covariate was the productive life (d) divided by 365, and was set to 1 if the productive life was 365 or longer.The residuals of all models were checked using residual plots.
For the models with r auto , heteroskedastic residuals were observed, which was due to a skewed distribution of r auto .This was solved by removing outliers for r auto using the interquartile range method applicable to skewed distributions, where records outside the first and third quartile ±1.5 × the interquartile range were removed (Hoaglin et al., 1986).As a result, the analysis for r auto included 1,301 records.The residuals of the models of both LnVar and r auto then were homoscedastic.There were no signs of nonlinear relationships between the resilience indicators and the dependent variables.For most models, the residuals were roughly normally distributed upon visual inspection, although the residuals were often left-skewed (LGM per productive year, slaughter revenues per productive year) or right-skewed (LGM, lifetime milk revenues, lifetime calving revenues and costs, lifetime feed costs, lifetime rearing costs, lifetime insemination costs, lifetime disease costs, calving revenues and costs per productive year, rearing costs per productive year, insemination costs per productive year, disease costs per productive year, destruction costs per productive year, calving age, lifetime yield and components, lifetime VEM, lifetime discarded milk and components, number of inseminations per productive year, disease count per productive year for individual diseases).This skewness seems due to characteristics of the data (e.g., some cows had long productive life and, therefore, high lifetime figures, and most cows had 0 or close to 0 cases of a disease per productive year, except for some cows with high disease count), and there is no reason to believe that it is due to errors in the data.Therefore, no data were removed and the skewness of residuals should be kept in mind when interpreting results.

Descriptive Statistics
Table 4 shows the descriptive statistics of the resilience indicators and mean milk yield in lactation 1. Cows produced on average 25 kg of milk per d in lactation 1 with an LnVar of 1.33 and an r auto of 0.56.Table 5 shows the descriptive statistics of the gross margin, revenues, and costs per cow throughout lifetime and expressed per productive year.On average, cows generated €4,362 gross margin throughout life, ranging from €-1,428 up to €16,716.Cows generated on average €1,229 per productive year, ranging from €-1,428 to €2,506.The highest revenues were the milk revenues, which were on average €9,153 throughout the entire lifetime and €2,909 per productive year.The highest costs were the feed costs, which were on average €3,078 throughout the entire lifetime and €986 per productive year.Total treatment costs, consisting of medicine costs, labor costs of veterinarian and farmer, and discarded milk, were the second lowest costs, with on average €145 throughout life and €43 per productive year.Large variation in disease costs existed, ranging from €0 up to €3,581 per cow in her lifetime and €594 per productive year.Lifetime slaughter revenues and destruction costs were not continuous (a cow either had the cost or not) and were not included in Table 5. Slaughter revenues (€665) were present for 84% of all cows.Destruction costs (€61.80) were present for the other 16% of cows, which died on farm.Cows that did have slaughter revenues, had on average €258 slaughter revenues per productive year.Cows that did have destruction costs, had on average €4.14 destruction costs per productive year.Descriptive statistics of traits underlying the economic data are in Appendix Table A2.

Associations Between Resilience Indicators and Profit, Revenues, and Costs, and Underlying Traits
Associations between the resilience indicators and the traits in Tables 6, 7, 8, and 9 are corrected for several covariates and factors, and should be interpreted as as- sociations that would be observed among cows born in the same year on the same farm with the same ADMY in lactation 1.The regression coefficients of ADMY are not discussed, but can be found in the Appendix.The estimates for each herd and birth year are not shown.
LnVar.Natural log-transformed variance had significant negative associations with LGM, lifetime milk revenues, lifetime calving revenues, lifetime feed costs, lifetime calving costs, and lifetime insemination costs (Table 6).The regression coefficients show that cows with low LnVar (good resilience) had higher LGM, higher milk revenues, and higher calving revenues, but also higher feed costs, calving costs, and insemination costs than cows with the same ADMY but high LnVar.
To illustrate the size of the regression coefficients: if LnVar decreased with 1 standard deviation (resilience improved) while ADMY remained the same, LGM increased with €300.Among all significant associations (based on P-value) for LnVar, the largest regression coefficients were those of LGM, milk revenues and feed costs, and the smallest were those of insemination costs and calving revenues.
Expressed per year of productive life, only the gross margin and rearing costs were significantly associated with LnVar.The regression coefficients show that cows with low LnVar (good resilience) had higher profit per year and lower rearing costs per year of productive life than cows with the same ADMY but high LnVar.
Natural log-transformed variance was significantly associated with many traits underlying the costs and revenues (Table 7).The regression coefficients show that cows with low LnVar (good resilience) had a longer lifespan and productive life, a higher lifetime milk, fat, protein, and lactose yield, and higher lifetime feed requirements than cows with the same ADMY but high LnVar.Natural log-transformed variance did not have a significant association with the number of disease events per productive year.However, when looking at diseases separately, LnVar was significantly and positively associated with number of cases of clinical mastitis per productive year, but negatively associated with number of cases of ketosis per productive year (Table 8).
R auto .No significant associations were shown between r auto and LGM, revenues, or costs (Table 9).However, expressed per year of productive life, total treatment costs and destruction costs were significantly associated with r auto.The regression coefficients show that cows with low r auto (good resilience) had lower total treatment costs and destruction costs per year than cows with the same ADMY but high r auto .Low r auto (good resilience) was not significantly associated with any of the traits underlying the costs and revenues (Table 7) and not with number of disease cases per year for any of the individual diseases (Table 8).

DISCUSSION
For this study, we had detailed data on milk yield, inseminations, and treatments throughout the entire lifetime of many cows available.This made it possible to quantify many real-life lifetime costs and revenues for individual cows and relate them to the resilience indicators.This approach is different from other studies that investigated the economics of resilience, which completely relied on theory-based simulation models (Berghof et al., 2019;Knap and Doeschl-Wilson, 2020).Even though we relied to a larger extent on real data, we did have to make large assumptions on feed intake and BW, because we had no data on these traits.Feed intake was calculated as a function of milk yield and BW (which was assumed the same between cows), which neglects possible differences in feed required for maintenance between cows.Because resilient cows likely use more feed for maintenance (Poppe et al., 2020;Martin et al., 2021), and feed is the largest contributor to costs (Table 5), results may change when real feed intake data and BW would be used.Furthermore, slaughter price was assumed to be the same for all cows.However, as resilience likely has an association with body condition (Poppe et al., 2020), slaughter weight and, therefore, slaughter price may be associated with resilience.As such, repeating this analysis on farms with many years of feed intake and BW data, in addition to milk yield, inseminations, and treatment data, would be of great value.Such commercial farms may not be available, but research farms may offer a solution.For example, Simm et al. (1994) had detailed feed intake, milk yield, health, and insemination data available from a research farm and, therefore, were able to calculate realized profit.Nevertheless, the data used in this study still gave us novel insights into the association between resilience and at least several revenues and costs, while taking into account differences in lifespan.For this study, 21 farms were selected based on having an AMS for many years and having treatment registrations.Before interpreting the results, it is important to evaluate if these farms are representative for the average Dutch situation.The selected herds may differ from the average Dutch situation because most Dutch farms do not have AMS (Stichting, 2021), and have incomplete treatment registrations.Nevertheless, when the requirement on the treatment registrations was lifted and the analyses were repeated (64 farms with 4,583 cows then met all requirements), regression coefficients were similar to what we found in this study, although r auto did have stronger, but still insignificant, associations with lifetime milk revenues and feed costs (data not shown).The similar results suggest that the requirement on treatment registrations does not create bias.Moreover, the lifetime figures of the cows in our study were close to the mean lifetime figures across the Netherlands (Table 10).In summary, our data seems representative for the Dutch situation, but the applicability of our results for farms with milking parlors remains to be tested.
For many traits reflecting revenues, costs, profit, or other lifetime figures, the models explaining them had skewed residuals.This seemed due to characteristics of the data rather than errors.However, the skewness implies that the significance of results discussed in the following paragraphs should be interpreted with caution.
A significant negative association was observed between LnVar and LGM, which means that cows with stable milk yield in lactation 1 generated a higher LGM than cows that had the same milk yield level, but with more fluctuations.The association between LnVar and LGM can mainly be explained by the association with lifetime milk revenues (Table 6).The negative association between LnVar and milk revenues can probably be explained by the negative association of LnVar with productive life; on average, cows with low LnVar had a longer productive life and, therefore, higher lifetime milk yield than cows with high LnVar (Table 7).A decrease of 1 standard deviation LnVar while keeping ADMY the same would coincide with an increase of productive life of 58 d and an increase in lifetime milk yield of 1,238 kg.The association of LnVar with productive life is also the reason for the significant associations with lifetime insemination costs and lifetime calving costs and revenues; the association was not significant anymore when these variables were expressed per year.The association of LnVar with productive life is in line with the negative genetic correlation between LnVar and longevity (Poppe et al., 2020(Poppe et al., , 2021a) ) and the negative association between mean LnVar within herd and proportion of cows in a herd that survived to second lactation (Poppe et al., 2021b).The association is also in line with the expectation that animals that have good resilience or robustness have long productive life (Friggens et al., 2017).However, Adriaens et al. (2020) found that cows with variable milk yield in lactation 1 had a higher resilience rank (which was largely determined by lifespan) than cows with stable milk yield.The difference with our study may be because of a difference in definition between productive life and resilience rank or because Adriaens et al. (2020) did not adjust for ADMY, whereas we did.In summary, the favorable association between having a stable milk yield, which represents good resilience, with LGM is mainly due to an association with lifespan.The r auto was not significantly associated with LGM or any of the underlying lifetime costs or revenues.However, we see a significant positive association with yearly treatment costs, which suggests that having low r auto (good resilience) is at least important for having low yearly costs associated with diseases.This observation confirms the claim that easy management and low labor and treatment costs due to few health problems are important advantages of resilience (Elgersma et al., 2018;Berghof et al., 2019).However, when looking at separate diseases, r auto was not significantly associated with any of them.The largest coefficients were positive though, so apparently the summed costs of these diseases were sufficient to make the association with total treatment costs significant.Nevertheless, when looking across the total life of cows, having low or high r auto does not seem to have an economic benefit.
Unlike r auto , LnVar was not significantly associated with yearly treatment costs.This was surprising because better health is one of the most often mentioned advantages of resilience (Elgersma et al., 2018;Berghof et al., 2019).Two explanations can be given for the insignificant association between LnVar and yearly treatment costs.The first explanation is that LnVar was favorably associated with some diseases (clinical mastitis; Table 8), but unfavorably with others (ketosis; Table 8), which levels out the economic effects.The significant association with clinical mastitis is in line with Kok et al. (2021).The second explanation for the insignificant association is that farmers likely did not register all (minor) health problems that required attention.Labor costs due to unregistered disturbances could be dealt with similar to Berghof et al. (2019).Those authors assumed that cows require labor if their milk yield drops below a certain value, and labor costs automatically rise with increasing Ln-Var.However, the assumption that drops in milk yield require labor has not been tested yet and, therefore, was not applied here.It should be mentioned, too, that the residuals from the models testing the association between the resilience indicators and individual diseases were very skewed for many diseases, which is probably because of the low incidence (Appendix Table A1).Re-testing in herds with higher incidence of diseases may be valuable to obtain better insight into the association between resilience indicators and individual diseases.Even though significant associations of LnVar and r auto with yearly treatment costs or individual diseases were found, treatment costs were minor compared with other costs and revenues.Total lifetime treatments costs only accounted for 2.6% of all variable lifetime costs (Table 5).Similarly, health costs only accounted for 4% of total costs in Simm et al. (1994).Therefore, the economic importance of treatments seems limited.However, it is important to acknowledge that the disease costs did not include decreased milk production due to disease and increased culling risk, because these were already accounted for by the lifetime milk yield based on daily milk yield records and the length of productive life.Furthermore, it is important to acknowledge that the significant associations with individual diseases can still be important to a farmer.In this study, a standard labor price of €18/h was used, but an hour of labor may be worth much more to a farmer in case of unanticipated extra labor due to health problems.Huijps et al. (2008) showed that some farmers valued their hourly rate as high as €200 in case of mastitis.Indeed, when we used a labor price that was 10 times higher than the original labor price (€180/h), total treatment costs were relatively larger compared with other costs and revenues.Now, total treatment costs accounted for 5.0% of total lifetime costs.In addition, with a labor price of €180/h, the association between r auto and total treatment costs per productive year was 1.4 times as strong (β = 36) as previously in Table 9 (β = 25).This illustrates that good health through good resilience is economically important for farmers, as long as they value their time highly enough.
This study focused on the resilience indicators Ln-Var and r auto , as a follow-up on previous studies by Poppe et al. (2020Poppe et al. ( , 2021a,b,c),b,c).However, comparable economic analyses on other resilience indicators would be interesting as well.Examples are the lifetime resilience rank, or additional traits describing fluctuations in daily milk yield or daily activity described by Adriaens et al. (2020).Furthermore, economic analysis of traits describing resilience to specific disturbances would be interesting, for example heat tolerance based on reaction norm models (Carabaño, et al., 2017(Carabaño, et al., , 2019)).Moreover, the calculation of the resilience indicators based on daily milk yield in this study may be optimized in the future.For example, the effect of different methods for calculating daily milk yield from AMS visit data on the resilience indicators may be investigated.In this study and Poppe et al. (2020Poppe et al. ( , 2021a,b,c),b,c), we assigned a proportion of the first milk record of a day to the previous day, with the proportion depending on the milking interval and time since midnight.However, the effect of milking interval length on the amount of milk was not corrected for any further, and therefore the higher amount of milk produced on days with more AMS visits (Barnes et al., 1990;Bar-Peled et al., 1995;Alex et al., 2015) was not adjusted to the amount that would have been produced with fewer AMS visits.Official ICAR methods do adjust for this effect by relying on weightings based on milk rates on the current and previous days (Lazenby et al., 2002;Bucek et al., 2019), which raises the question if this approach should be used in the current study as well.However, for the purpose of developing resilience indicators, this approach is not suitable.Resilience indicators rely on fluctuations between realized milk yield from day to day.Smoothing the realized milk yields, by using weighted averages of milk rates on multiple days and by adjusting for num-ber of milk visits, will remove variation between days that is informative about resilience.For example, if a cow normally visits the AMS 3 times per day, but due to disease this is temporarily reduced to 2 times, this will contribute to larger variation between days, which is exactly the kind of information that is needed for the resilience indicators to reflect resilience.In previous studies it was already shown that the resilience indicators in this study reflect resilience (Poppe et al., 2020(Poppe et al., , 2021a,b,c),b,c), and it is very unlikely that they will improve by smoothing the daily milk yield records.The current study adds even more confirmation that the resilience indicators reflect resilience, given their associations with lifespan and yearly disease costs.

CONCLUSIONS
The association between 2 resilience indicators (Ln-Var and r auto of daily milk yield deviations) and LGM was investigated using data obtained throughout the entire lifetime of cows.The variance had a significant negative association with LGM, which means that cows with stable milk yield in parity 1 generated on average a higher LGM than cows with the same milk yield level in parity 1 but with more fluctuations.Unlike the variance, autocorrelation was not significantly associated with LGM.However, it was significantly associated with yearly treatment costs, which is important for ease of management.In summary, the importance of resilience for total gross margin generated by a cow at the end of life was confirmed by the significant association of LnVar with LGM.
Observational study on associations between resilience indicators based on daily milk yield in first lactation and lifetime profitability M. Poppe, 1 * † R. F. Veerkamp, 1 H. A. Mulder, 1 and H. Hogeveen 2

Figure 1 .
Figure 1.Flow diagram of selection of herds (left, blue) and then cows within herds (right, orange).The numbers represent the number of herds or cows left in the data set after the previous selection step.
Figure A1.Boxplots that show variation in the proportion of cows with a disease registration between herds.Green line indicates median; outer borders of box are 25th and 75th percentiles; box represents interquartile range; whiskers indicate 0 and 100th percentiles; circles are outliers.
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY 5,799 herds, from January 14, 1998, to September 4, 2020.The second data set was obtained during official milk production registration, which takes place every 3 to 6 wk depending on herd, and included records on fat, protein, and lactose content of the milk.This data set contained 39,239,081 records on 1,499,375 cows in 5,786 herds, from January 4, 1991, to August 27, 2020.The third data set contained registrations of inseminations, and contained 11,044,353 records on 1,506,583 cows in 15,846 herds, from February 14, 1990, to August 28, 2020.The fourth data set contained records of health disorders registered by farmers, and by the claw health program DigiKlauw (DigiKlauw, 2021).The data set contained 4,186,231 records on 893,260 cows in 9,200 herds, from May 23, 2010, to September 5, 2020.A total of 4,701 herds had records in all 4 data sets, but with varying degrees of data quantity and quality.

Table 1 .
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY Prices used for calculation of costs and revenues

Table 2 .
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY Costs of diseases and other treatments, provided by veterinarian 1Assuming an hourly rate of €18/h and an estimate of the time spent by the farmer based upon authors' expertise and consultation of farmers. 2

Table 3 .
Costs of claw disorders, provided by F. Edwardes (Wageningen University and Research, Wageningen, the Netherlands, personal communication) 1Assuming an hourly rate of €18/h and an estimate of the time spent by the farmer based upon authors' expertise.
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY

Table 5 .
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY Descriptive statistics of gross margin, revenues, and costs, expressed per lifetime and per year of productive life Item 1 IQR = interquartile range.

Table 6 .
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY   Intercept, regression coefficients (β), SE, and P-values of regression coefficients for the resilience indicator natural log-transformed variance of milk yield deviations (LnVar) from the analysis of covariance models explaining gross margin, revenues, and costs across lifetime and per year of productive life from LnVar 1

Table 7 .
Poppe et al.:RESILIENCE AND LIFETIME PROFITABILITY Intercept, regression coefficients (β), SE, and P-values of regression coefficients from the analysis of covariance models explaining traits across lifetime and per year of productive life from average daily milk yield (ADMY) and the resilience indicator natural log-transformed variance (LnVar) or lag-1 autocorrelation of milk yield deviations (r 1Regression coefficients for ADMY are shown in Appendix TableA4.

Table 8 .
Poppe et al.: RESILIENCE AND LIFETIME PROFITABILITY   Intercept, regression coefficients (β), SE, and P-values of regression coefficients from the analysis of covariance models explaining number of disease events per year of productive life from the resilience indicator natural log-transformed variance (LnVar) or lag-1 autocorrelation of milk yield deviations (r auto ) 1 Regression coefficients for average daily milk yield are shown in Appendix TableA5.

Table 9 .
Intercept, regression coefficients (β), SE, and P-values of regression coefficients for the resilience indicator lag-1 autocorrelation of milk yield deviations (r auto ) from the analysis of covariance models explaining gross margin, revenues, and costs across lifetime and per year of productive life from r auto

Table 10 .
Comparison between mean lifetime figures in this study and mean lifetime figures of the NetherlandsOnly cows born before 2011 were included (at least the opportunity to become 10 yr old), because cows born in recent years showed an overrepresentation of cows that were culled early and therefore had low lifetime figures.