Get production status of group
getProductionStatus( ped, minParentAge = 3, maxOffspringAge = NULL, housing = "shelter_pens", currentDate = Sys.Date() )
ped | Dataframe that is the `Pedigree`. It contains pedigree
information. The |
---|---|
minParentAge | Numeric values to set the minimum age in years for an animal to have an offspring. Defaults to 2 years. The check is not performed for animals with missing birth dates. |
maxOffspringAge | Numeric values to set the maximum age in years for an animal to be counted as birth in calculation of production status ratio. |
housing | character vector of length 1 having the housing type, which is either "shelter_pens" or "corral". |
currentDate | Date to be used for calculating age. Defaults to
|
production
-- Ratio of the number of births that live >30
days to the number of females >= 3 years of age.
Description of how Production and Production Status (color) is calculated.
The Production Status is calculated on September 09, 2019, Births = count of all animals in group born since January 1, 2017 through December 31, 2018, that lived at least 30 days.
Dams = count of all females in group that have a birth date on or prior to September 09, 2016.
Production = Births / Dams
Production Status (color)
Shelter and pens
Production < 0.6; Red
Production >= 0.6 and Production <= 0.63; Yellow
Production > 0.63; Green
Corrals
Production < 0.5; Red
Production >= 0.5 and Production <= 0.53; Yellow
Production > 0.53; Green
This code may need to be modified to allow the user to supply a list
of IDs to include as group members. Currently each animal in the
provided pedigree (ped
) is considered to be a member of the
group.