LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #13   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 837
Default calculating probabilty of x number of successes with multiple

"joeu2004" wrote:

Not to beat a dead horse and certainly not to promote this approach
more than it deserves (which is simply in the genre of quick-and-dirty
solutions), but it occurred to me that in the OP's original posting,
10 successes in 21 trials was merely an example, and iandjmsmith's
excellent "xtestc3" function provides the generality to solve any K-in-
N problem. So I wondered how much more effort it would take to hack a
general solution along the same (inelegant) lines of generating all
combinations.


I would still argue for the probability generating function as the simplest,
most elegant, and most general solution. In Maxima, only 2 lines of code are
required

p:[2,4,9,6,5,4,7,3,1,5,6,7,9,1,2,2,2,5,6,7,9]/10;
expand(product( 1-p[i]+p[i]*t, i,1,length(p)));

which returns a polynomial in t, where Pr(X=k) is the coefficient of t^k.
This also extends immediately to more complicated probability models as
described in the wikipedia article cited in my original post.

Jerry
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why is Excel calculating a number? Gator Excel Discussion (Misc queries) 2 January 4th 08 06:08 PM
Calculating Time with a number value Corey Excel Worksheet Functions 2 December 28th 06 05:29 AM
Probabilty - Binomial - a simulation game? Rob Eyes Excel Worksheet Functions 4 May 2nd 06 05:36 PM
Text number to number value for calculating ddiebold7 Excel Worksheet Functions 3 June 13th 05 12:48 PM
Calculating number of days Carlos Excel Worksheet Functions 3 March 1st 05 08:23 PM


All times are GMT +1. The time now is 03:23 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"