-
-
Save aditya0811/f556ff74178cedd42fd80072f6406e91 to your computer and use it in GitHub Desktop.
sampleone
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from math import sqrt | |
import numpy as np | |
a=np.array([27.5, 21.0, 19.0, 23.6, 17.0, 17.9, 16.9, 20.1, 21.9, 22.6, 23.1, 19.6, 19.0, 21.7, 21.4,22,23,32.5,43.4,12.4,23.4]) | |
pop_mean=27.5 | |
num_a=len(a) | |
test_statistic= (a.mean()-pop_mean)/(a.std()/sqrt(num_a)) | |
print(test_statistic) | |
>>>-3.855 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment