<< test1r Tests test2r >>

Stixbox >> Stixbox > Tests > test2n

test2n

Tests two normal samples with equal variance

Calling Sequence

pval=test2n(x,y)
pval=test2n(x,y,c)
[pval,cimean]=test2n(...)
[pval,cimean,cisigma]=test2n(...)

Parameters

x :

a n-by-1 matrix of doubles

y :

a n-by-1 matrix of doubles

c :

a 1-by-1 matrix of doubles, the confidence level for the confidence intervals (default 0.95).

pval :

a 1-by-1 matrix of doubles, the probability that Student statistic based on x and y is as far from 0 as it is actually, or further away under hypothesis that theoretical means are equal.

cimean :

a 1-by-3 matrix of doubles, the confidence interval for the difference of means.

cisigma :

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

Description

Tests and confidence intervals based on two normal samples with equal variance.

The confidence intervals are of the form

[LeftLimit, PointEstimate, RightLimit]

Examples

x=distfun_normrnd(0,1,20,1);
y=distfun_normrnd(0,1,20,1);
pval=test2n(x,y)
// Get a 95% confidence interval for the
// difference of means
[pval,cimean]=test2n(x,y)
// Get a 90% confidence interval for the mean
[pval,cimean]=test2n(x,y,0.9)
// Get a 95% confidence interval for the
// difference of standard deviations
[pval,cimean,cistd]=test2n(x,y)

Authors


Report an issue
<< test1r Tests test2r >>