H0: μd ≥ = ≤ μ0
H1: μd < ≠ > μ0
The following R code should produce the same results:
Target: the test compares the means of the same items in two different conditions or any others connection between the two samples when there is a one to one connection between the samples. The test uses the t distribution. moreTwo-tailed test example:
Treatment is given to 50 people to reduce the cholesterol level. The expected reduction is 10mg/dL. The researcher takes two measures for each person before and after the treatment. The average reduction of the cholesterol level is 12mg/dL. (xd
= 12mg/dL n=50). The standard deviation of the reduction is 2.2mg/dL. Sd
=10mg/dL In this case, the researcher would like to know if μ0
Both results are interesting, if the reduction is larger than the expected or if it is lower.Right-tailed example.
Does the treatment for pattern hair loss effective?
Measurment: hair density, hairs per square cm.
Check the same person
before and after 6 months treatment.
: the base assumption - identical results before and after the treatment.
: the opposite of base assumption - after treatment gets a larger density.