<< kstwo Tests test1n >>

Stixbox >> Stixbox > Tests > test1b

test1b

Bootstrap test that mean equals zero

Calling Sequence

pval=test1b(x)
pval=test1b(x,c)
pval=test1b(x,c,b)
[pval,cimean]=test1b(...)
[pval,cimean,cistd]=test1b(...)

Parameters

x :

a m-by-n matrix of doubles

c :

a 1-by-1 matrix of doubles, c in [0,1], the confidence level for the confidence intervals (default=0.95)

b :

a 1-by-1 matrix of doubles, b>=1, the number of bootstrap samples (default=2000)

pval :

a 1-by-1 matrix of doubles, the probability that the mean is zero

cimean :

a 1-by-3 matrix of doubles, the confidence interval for the mean

cistd :

a 1-by-3 matrix of doubles, the confidence interval for the standard deviation

Description

Performs the bootstrap t test for the equality of the mean to zero and computes confidence interval for the mean.

Another name for the bootstrap t is studentized bootstrap.

The confidence intervals are of the form

[LeftLimit, PointEstimate, RightLimit]

Examples

x=distfun_normrnd(0,1,20,1);
pval=test1b(x) // pval is close to 1

x=distfun_normrnd(10,1,20,1);
pval=test1b(x) // pval is close to 0

x=distfun_chi2rnd(3,20,1);
pval=test1b(x)
// Set the confidence level
pval=test1b(x,0.9)
// Set the number of bootstrap samples
pval=test1b(x,[],100)
// Get a confidence interval for the mean
[pval,cimean]=test1b(x)
// Get a confidence interval for the standard
// deviation
[pval,cimean,cistd]=test1b(x)

Authors


Report an issue
<< kstwo Tests test1n >>