ht_onesample_z(A, m, std, alpha, type)

Hypothesis test for one population mean with known standard deviation. The sample is stored in array A, m is the mean to test, std is the standard deviation, and the significance level is alpha. Parameter type can be 0 (left tail), 1 (right tail), or 2 (both tails).
Assumes population is normal or the sample is large.


See also ht_onesample_pro ht_onesample_wilcoxon ht_onesample_std 


Example


(See NOTE below)


a=(686, 993, 992, 433, 620, 775, 743, 574, 1113, 647, 634, 672, 734, 850, 879, 641, 858, 609)

( 686 993 992 433 620 775 743 574 1113 647 634 672 734 850 879 641 858 609 )


ht_onesample_z(a, 800, 188, .05, 0)


One-sample Z-Test.

Hypothesis test for one population mean. Known standard deviation.

Ho : m==800.0

Ha : m<800.0

Significance level : 0.05 (5.0%)

Results:

Test statistics Z : -1.1872874499710284

Critical left value found is -1.6448536056633434

P value is : 0.1175571283394165

Do not reject the null hypothesis.





NOTE: The data used in this example was taken from the textbook Introductory Statistics 6th Ed. by Neil A. Weiss with kind permission of Addison Wesly Longman, Inc. (AWL). AWL does not endorse nor it supports the Calcugator.