my_t.test: t test function

Description Usage Arguments Value Examples

View source: R/my_t_test.R

Description

This function applies t test to input data.

Usage

1
my_t.test(x, alternative, mu)

Arguments

x

Numeric input of data to be tested

alternative

String to specify the type of aternative hypothesis, either 'two.sided', 'less', or 'greater'

mu

Numeric input of null hypothesis

Value

List object containing t score, degree of freedom, type of alternative hypothesis, and p value of x

Examples

1
2
3
my_t.test(rnorm(10, 0, 1), "two.sided", 5)
my_t.test(rnorm(10, 0, 1), "less", 5)
my_t.test(rnorm(10, 0, 1), "greater", 5)

SylviaDu99/Project3Package documentation built on March 24, 2020, 5:29 p.m.