From 879b9b8e919b5ebcb25a275987450362683acb9e Mon Sep 17 00:00:00 2001 From: "Ryan C. Cooper" Date: Tue, 3 Sep 2019 10:15:05 -0400 Subject: [PATCH] fixed check_lab00.py --- check_lab00.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/check_lab00.py b/check_lab00.py index 2e88a64..a1c0be0 100644 --- a/check_lab00.py +++ b/check_lab00.py @@ -1,4 +1,5 @@ import numpy as np +from scipy.stats import norm, t def check_p01(data): mu=np.mean(data) @@ -36,7 +37,7 @@ def check_p03(data1,data2): print('t=%1.2f'%tstat) - df=2*N-2 + df=N1+N2-2 if tstat>t.interval(0.95, df)[1] and (mu1-mu2)/mu1<0.1: points=2 print('Nice work') @@ -46,4 +47,4 @@ def check_p03(data1,data2): return points if __name__=='__main__': - print('This is the library to check Lab 00 prework') \ No newline at end of file + print('This is the library to check Lab 00 prework')