Farming is a business. Like any other business they seek efficiencies in their production process. A dairy farm’s product is milk. To ensure cows produce milk, farmers invest lots of time and resources in their breeding protocols. Any cycle when a cow is eligible to become pregnant and a pregnancy is not achieved creates a loss for the farm. Yet, it’s important to balance the costs of the breeding protocol against the gains in pregnancy rate.
In this case, a farm is trying to decide whether or not a product called CiDR can be reused from one breeding cycle to the next or if they should use a new product every cycle. The product is an insert that delivers progesterone and increases the odds of pregnancy.
Please analyze the data provided and make a recommendation regarding the effectiveness of new or reused CiDR in terms of cow pregnancies.
Note, the farm has requested analysis of its timed articificial insemination cows (TAI) only.
The data contain the following fields:
##Things you’ll need You should be following the best coding practices as outlined by previous class lectures and R examples:
Follow our outlined workflow
Create a new chunk (thre grayed out areas that start and end with ```) for each task in the workflow. Chunks can be added by clicking code from the top menu and selecting “Insert Chunk” or through the keyboard shortcut: ctrl+alt+I
Be sure to name your chunks appropriately. The first chunk has been given to you already
The Statistics in the Tidyverse assignment is good reference material
“Knit” your complete markdown file and submit the resulting pdf to canvas As long as your code does not contains errors (you can run each chunk and they work), it should knit succesfully
##Loading Data and Filtering into TAI 1
Heifer_Data<- read.csv("Heifer Breeding.csv")
TAI_Filter<-Heifer_Data %>%
filter(TAI==1)
##Filtering CiDR - Reused (0)
CiDR_0<-TAI_Filter %>%
filter(New==0)
##Filtering CiDR - New (1)
CiDR_1<-TAI_Filter %>%
filter(New==1)
##Showing Distrubtion for Pregnancy Rate with Reused CiDR
ggplot(CiDR_0, aes(x=Preg,)) +
geom_histogram(binwidth=0.5)
##Showing Distrubtion for Pregnancy Rate with New CiDR
ggplot(CiDR_1, aes(x=Preg,)) +
geom_histogram(binwidth=0.5)
##Conclusion After evaluating the histogram graphics, it shows that reusing the CiDR versus using new CiDR really does not make a large difference. The data above is nearly identical between reusal and new CiDR. In conclusion, the compnay should be reusing the CiDR to save funds and conserve current pregnancy rates.