So I have a coin that I tossed for 1000 times and I get 560 heads.
Is my coin a fair coin?
Answer: H0: Number of heads = Number of tails Ha: Number of heads Number of tails At a 10% significance level (=0.1), > qbinom(.05,1000,.5) [1] 474 > qbinom(.95,1000,.5) [1] 526