here is the ENDDAY code with 9 things
ENDDAY = c(1,1,1,1,1,1,1,1,1)
Another related code hereunder
Day the animal is slaughtered (days)
# Is initially 9999, but is replaced by the correct number of days at slaughter
ENDDAY[j] <- min(SLAUGHTERDAYACT[1:i,j])
# Beef production at slaughter (kg per animal)
if(ENDDAY[j] < 9999) BEEFPROD[j] <- BEEFPRODACT[ENDDAY[j],j]
# Beef production (kg beef per head per year)
if(ENDDAY[j] < 9999) BEEFPRODYEAR[j] <- BEEFPRODACT[ENDDAY[j],j]/(TIME[ENDDAY[j],j]/365)
# Live weight production at slaughter (kg per animal)
if(ENDDAY[j] < 9999) LWPROD[j] <- LWPRODACT[ENDDAY[j],j]
# Live weight production (kg live weight per head per year)
if(ENDDAY[j] < 9999) LWPRODYEAR[j] <- LWPRODACT[ENDDAY[j],j]/(TIME[ENDDAY[j],j]/365)
The model is very long with many codes. Would you be available to assist me via an online short meeting where i can share my screen, please contact me via direct message.