void page5() { String t = "Step 4 - The Test Statistics (continued)"; textFont(myboldfont, 18); text(t, 30, 160); if (aStudy.known == 1) { image(test1, 260, 190); t = "Plug in Y bar as " + nf(aStudy.mean, 1, 2) + ", mu zero as " + nf(aStudy.muo, 1, 2) + ", sigma as " + nf(aStudy.sd, 1, 2) + ", and n as " + aStudy.samplesize; } else if (aStudy.samplesize > 30) { image(test2, 260, 190); t = "Plug in Y bar as " + nf(aStudy.mean, 1, 2) + ", mu zero as " + nf(aStudy.muo, 1, 2) + ", S as " + nf(aStudy.sd, 1, 2) + ", and n as " + aStudy.samplesize; } else { image(test3, 260, 190); t = "Plug in Y bar as " + nf(aStudy.mean, 1, 2) + ", mu zero as " + nf(aStudy.muo, 1, 2) + ", S = " + nf(aStudy.sd, 1, 2) + ", and n as " + aStudy.samplesize; } if ((aStudy.known == 1) || (aStudy.samplesize>30)) { t += ". Calculate the value of Z. Type in the following textbox (with at least 3 decimal places) then click Answer:"; } else { t += ". Calculate the value of t. Type in the following textbox (with at least 3 decimal places) then click Answer:"; } int tempx = drawStrings(t, 30, 255+25, 25); fill(0, 0, 255); drawStrings(feedback, 80, 380, 25); tf3.setVisible(true); tf3.setXY(tempx+10,313); cb4.setVisible(false); }