May 2019
Beginner to intermediate
266 pages
5h 57m
English
In this hypothesis testing, you can only specify a direction to the dataset mentioned previously. Here, we will use the same function with the alternative equal to (=) instruction to switch the emphasis from a two-sided test (the default) to a one-sided test. The choices that we have are two.sided, less, or greater, and the choice can be abbreviated, as shown in the following command:
> t.test(GlassDataset$RI, mu = 5, alternative = 'greater')One Sample t-testdata: GlassDataset$RIt = -16771, df = 213, p-value = 1alternative hypothesis: true mean is greater than 595 percent confidence interval:1.518022 Infsample estimates:mean of x1.518365> t.test(GlassDataset$Type, mu = 5, alternative = 'greater')One Sample t-test ...Read now
Unlock full access