skewt.test: Bootstrapped Skewness-Adjusted t-test

Description Usage Arguments Value References Examples

Description

Performs one sample bootrsapped skewness adjusted t-test on vectors of data.

Based on 'getAnywhere(t.test.default)' and "Improved Methods for Tests of Long-Run Abnormal Stock Returns" by Lyon et al (1999)

Usage

1
2
3
4
skewt.test(x, ...)

## Default S3 method:
skewt..test(x, mu = 0, conf.level = 0.95, b.frac = 1/4, N = 10000, ...)

Arguments

x

a (non-empty) numeric vector of data values.

mu

a number indicating the true value of the mean.

conf.level

confidence level of the interval.

b.frac

fraction of the total samples to use in the bootstrap.

N

number of repetitions for the bootsrap.

...

further arguments to be passed to or from methods.

Value

A list with class "htest" containing the following components:

statistic

the value of the skewness adjusted t-statistic.

parameter

the bootstrap standard deviation of the statistic.

p.value

the p-value for the test.

conf.int

a confidence interval for the statistic.

estimate

the estimated mean.

null.value

the specified hypothesized value of the mean.

alternative

a character string describing the alternative hypothesis.

method

a character string indicating what type of t-test was performed.

data.name

a character string giving the name(s) of the data.

References

Lyon, J. D., Barber, B. M., & Tsai, C.-L. (1999). Improved Methods for Tests of Long-Run Abnormal Stock Returns. The Journal of Finance, 54(1), 165–201. http://doi.org/10.1111/0022-1082.00101

Examples

1
2
3
4
5
6
7
8
install_github('waissbluth/skewttest')
library('skewttest')
# Generate 100 samples from a gamma distribution
x <- rgamma(100,2,1)
# Perform a skewed t-test
skewt.test(x, mu=2)
# Compare to traditional t-test
t.test(x, mu=2)

waissbluth/skewttest documentation built on May 3, 2019, 8:10 p.m.