One nice property that follows from the definition of chisquare is that a chisquare distrbution with two df is just the sum of two chisquare distributions with one df. Anyway, let's return to our problem of the 100 coin tosses that came up 60 heads and 40 tails. The probability of this chisquare is exactly the same as the two-tailed z probability we just obtained. Now here is where the math starts to get a little murky for me. Here is the next place where I can't quite give you all the math.
Rats run down a maze and have to select one of four arms.
Actually, now I can. The trick is to make it the sum of three independent zs. In actual data, you could enter the 32 observations individually, and SAS would tote them up for you. It involves two variables, and we want to know if one is related to another. Here is another problem from Howell, involving proper disposal of handbills.