blob: 4ef967626621bba0e819b0ae32944374b7f979b7 (
plain)
1
2
3
4
5
6
7
8
|
r = 30;
T = 600;
theta = 25;
val1 = cdfchi("PQ", 2*T/theta, 2*r);
val2 = 1- cdfchi("PQ", 2*T/theta, 2*(r+1));
pvalue = min(val1, val2);
disp(pvalue, "The pvalue is");
disp("H0 would be accepted when the significance level is 0.10");
|