**TI89**mainRdifptestQ¥Z÷() Prgm ClrIO Disp "1 = large, large","2 = large, finite","3 = finite, large","4 = finite, finite" Input c ClrIO If c=3 or c=4 Then Disp "1st population size" Input k Else 0k EndIf If c=2 or c=4 Then Disp "2nd population size" Input l Else 0l EndIf Disp "test difference" Input d Disp "1st number of yes" Input m Disp "1st sample size" Input p Disp "2nd number of yes" Input n Disp "2nd sample size" Input q Disp "level of significance" Input a If k=0 Then ¨(m/p*(1-m/p))s Else ¨(m/p*(1-m/p))*¨((k-p)/(k-1))s EndIf If l=0 Then ¨(n/q*(1-n/q))t Else ¨(n/q*(1-n/q))*¨((l-q)/(l-1))t EndIf s^2/p+t^2/qv (m/p-n/q-d)/¨(v)z s\nrmcdff(0,z,0,1)b b+.5l .5-br ClrIO If a>r Then Disp "reject (p1-p2) œ p" Else Disp "accept (P1-p2) œ p" EndIf If a>l Then Disp "reject (p1-p2) ž p" Else Disp "accept (p1-p2) ž p" EndIf If (a/2>r) or (a/2>l) Then Disp "reject (p1-p2) = p" Else Disp "accept (p1-p2) = p" EndIf Output 36,1,"test stat =" Output 36,70,round(z) Disp "tail values",{round(l,4),round(r,4)} EndPrgm äåÜÒ1