Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Math and Science (http://www.chiefdelphi.com/forums/forumdisplay.php?f=70)
-   -   Statistics Quiz#1 (http://www.chiefdelphi.com/forums/showthread.php?t=123814)

Basel A 01-01-2014 14:53

Re: Statistics Quiz#1
 
Quote:

Originally Posted by Ether (Post 1319077)
Thanks Ryan.

If anybody has access to R, Mathematica, MathCAD, or Maple, would you please post the value computed for p1?

I'm investigating which numerical package gives the most accurate answer.



Maple 17 and Mathematica 9.0 gave the same answer, a very large fraction that evaluates to 0.591634715653168147118256848279....

Here's the code:

Maple (with Digits set to 30):
Code:

evalf(CDF(RandomVariable(Binomial(2000, 1/3)), 671));
Mathematica:
Code:

N[CDF[BinomialDistribution[2000, 1/3], 671], 30]

Ether 01-01-2014 15:45

Re: Statistics Quiz#1
 
Quote:

Originally Posted by Basel A (Post 1319143)
Maple 17 and Mathematica 9.0 gave the same answer, a very large fraction that evaluates to 0.591634715653168147118256848279....

Thank you.

That confirms the 80-digit arbitrary-precision calc I did with Maxima.

The "very large fraction" has 953 digits in the numerator (and denominator). The first 80 digits of the decimal representation of that fraction are:

Code:

load(distrib)$
fpprec:80$
bfloat(cdf_binomial(671,2000,1/3));

0.59163471565316814711825684827930003268147312930167045093849129098685265637080124

Comparing the above to double-precision calculations:

0.591634715653168.....(Scilab)
0.59163471565317......(Maxima)
0.591634715653171.....(Matlab)
0.591634715653066.....(Octave)
0.59163471565245895...(Python)


... Scilab is the most accurate, Python the least, and Matlab is in the middle of the pack.

If you do the calcs using double-precision in Maple and Mathematica, what result do you get?




All times are GMT -5. The time now is 07:57.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi