my_t.test: Test function

Description Usage Arguments Value Examples

View source: R/my_t_test.R

Description

This function performs one and two sample t-tests on vectors of data.

Usage

1
my_t.test(x, alternative, mu)

Arguments

x

Numeric vector input of data.

alternative

A character string specifying the alternative hypothesis, must be one of two.sided, greater or less.

mu

A number indication the null hupothesis value of mean.

Value

A list contains the numeric test statistic, the degree of freedom, the value of the parameter alternative, and the numeric p-value.

Examples

1
my_t.test(my_iris$Sepal.Length, "less", 5)

Xiaoying-Z/Stat302Project03 documentation built on March 22, 2020, 2:09 a.m.