nan_ttest2 Hypothesis Tests nan_ztest

NaN Toolbox >> NaN Toolbox > Hypothesis Tests > nan_welchtest

nan_welchtest

Welch two-sample t test

Calling Sequence

H = nan_welchtest (x, y)
H = nan_welchtest (x, y,  alpha)
H = nan_welchtest (x, y,  alpha, tail)
[H,pval, stats] = nan_welchtest ( ... )

Parameters

x:

input vector

y:

input vector

tail:

H:

returns whether the Null-Hypotheses must be rejected.

pval:

p-value of the tested

Description

For two samples x and y from normal distributions with unknown means and unknown and not necessarily equal variances, perform a Welch test of the null hypothesis of equal means. Under the null, the test statistic t approximately follows a Student distribution with @var{df} degrees of freedom.

With the optional argument string tail, the alternative of interest can be selected. If tail is "~=" or "<>", the null is tested against the two-sided alternative mean (x) ~= m. If tail is ">", the one-sided alternative mean(x) > @var{m} is considered. Similarly for "<", the one-sided alternative mean(x) < m is considered. The default is the two-sided case.

Authors

nan_ttest2 Hypothesis Tests nan_ztest