quantile function: binomial

Econometrics questions and discussions
ac_1
Posts: 495
Joined: Thu Apr 15, 2010 6:30 am

quantile function: binomial

Unread post by ac_1 »

Hi Tom,

To assess 'if a coin is fair' as in https://stats.stackexchange.com/questio ... imes-is-bi

Is there an equivalent of R's qbinom, quantile function: binomial, in RATS?

thanks,
Amarjit
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: quantile function: binomial

Unread post by TomDoan »

No. The cumulatives of the binomial are usually quite well approximated (except for small N) by a Poisson for low values of p or a Normal for moderate levels. There is no shortcut for the true binomial probabilities to adding up the individual binomial probabilities.
ac_1
Posts: 495
Joined: Thu Apr 15, 2010 6:30 am

Re: quantile function: binomial

Unread post by ac_1 »

Thanks. My question is:

Is an econometric model forecasting the direction of the market better than if the forecasts would have been generated from a coin toss? 1 being correct direction, 0 incorrect direction.

Via R's qbinom a binomial with n=252 (say), probability p=0.5, and 95% confidence level i.e. alpha = 0,05; below 110 (number of correct directions) the forecasts from the econometric model are worse than if the forecasts would have been generated from a coin toss, and above 142 (number of correct directions) the econometric model forecasts are better than if the forecasts would have been generated from a coin toss.

Assuming the above is an appropriate method/result (if not, is there another technique?), how would I achieve the above in RATS?
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: quantile function: binomial

Unread post by TomDoan »

Doesn't the "homework solution" that you posted show that? With N=252, under the null of same accuracy as a coin toss, the mean is 126 and standard deviation is .5 x sqrt(252). That's +/- 15.56 for a 95% confidence band using the Normal approximation. Round that to an integer of 16 and you get 110 and 142.
Post Reply