May 2019
Beginner to intermediate
266 pages
5h 57m
English
This is also referred to as the student's t-test, which is a method for comparing two samples. It can usually be implemented to determine whether the samples are proper or different. This is considered a parametric test, and the data should be distributed normally.
R can handle the various versions of the t-test using the t.test() command.
The following command is used for our longley economic dataset to check the unemployment rate with respect to GNP:
> t.test(longley$GNP, longley$Unemployed)Welch Two Sample t-testdata: longley$GNP and longley$Unemployedt = 2.0045, df = 29.886, p-value = 0.05415alternative hypothesis: true difference in means is not equal to 095 percent confidence interval:-1.297804 138.032179sample estimates: ...Read now
Unlock full access