Methodology
Paired ttest was used to determine whether there is a significant difference between the ovarian diameter before hormonal injection on day zero and after hormonal injection on day 7 on dairy cattle.
Data: In this case, we used the vectors called ovarian diameter at day 0 and ovarian diameter at day 7. The total number of characters analyzed were 168.
t: This is the tstatistic test computed as 0.99147
df: This is the degrees of freedom associated with the t teststatistic. In this case, it’s 167
pvalue: This is the pvalue that corresponds to a t teststatistic of 0.99147and df = 167. The pvalue turns out to be 0.3229
Null hypothesis: In this case the null hypothesis is that the difference in means between the two diameters is equal to zero.
alternative hypothesis: The alternative hypothesis used for this particular ttest is that the true difference in means between the two diameter is not equal to zero.
95 percent confidence interval: This tells us the 95% confidence interval for the true difference in means between the two groups. It turns out to be [0.15490421 0.05133279].
H_{0}: µ_{1} = µ_{2} (the two population means are equal)
H_{A}: µ_{1} ≠µ_{2} (the two population means are not equal)
Because the pvalue of our test 0.3229 is greater than alpha = 0.05, we fail to reject the null hypothesis of the test. This means we have sufficient evidence to say that the mean diameter of the Ovarian between the two populations is not different.
Notes
The t.test() function in R uses the following syntax:
t.test(x, y, alternative = “two.sided”, mu = 0, paired = TRUE, conf.level = 0.95)
where:

x, y: The names of the two vectors that contain the data.

alternative: The alternative hypothesis. Options include “two.sided”, “less”, or “greater.”

mu: The value assumed to be the true difference in means.

paired: Whether or not to use a paired ttest.

conf.level: The confidence level to use for the test.
Assumptions
used a twosided alternative hypothesis.
tested whether or not the true difference in means was equal to zero.
used a paired ttest.
used a 95% confidence level.
Share with your friends: 