21forme said:
Don - please keep it public. Always learn something reading your posts.
OK, here's the mail I sent to Gronbog.
First, let me give you the sites for streak calculators that I have used over the years. They don't all agree, unfortunately, so it's hard to know which are the more accurate. (Strangely, two give one answer and two give another, a little more than 1% apart.) Then, I'll describe how to get a rough idea of the right answer, which isn't possible with straightforward numerical calculations. You can come close, but you can't be exact.
http://www.beatingbonuses.com/calc_streak.htm
http://completecurrencytrader.com/streak-probability-calculator.html#book_wrap
http://maxgriffin.net/CalcStreaks.shtml
https://sites.google.com/view/krapstuff/home
Finally, an interesting discussion can be found here:
https://wizardofvegas.com/forum/off...ak-calculator-and-calculating-streaks-runs/2/
Mike and I had numerous discussion of how to do this algebraically, and we agreed on a method that gets you close, but is just too cumbersome to do without a calculator for the more complicated scenarios. For this example, I'm going to go with 100 tosses of a fair coin, trying to get a streak of 5 heads. Now, right away, you have to understand that there can be confusion as to what that means. The first confusion is that you don't mean just
exactly one streak of five heads. It's all right to have two or three. Limiting it to exactly one would be somewhat silly. So, it's
at least one streak of five. But it's more than that. It's at least one streak of five
or more. That is, not only can you have several streaks of five, you can also have a streak of six or seven, and that counts towards your answer of at least one streak of five OR MORE. Again, it would be silly to have a streak of seven and not count it because it wasn't exactly five!
So now, let's get to the math. Visualize a horizontal number line from 1 to 100. We want a streak of five or more, but we're going to calculate NO streak of five or more and then do the usual 1 - routine to get the probability that it WILL occur. Actually, we're going to calculate will, won't, and then will. I'll explain.
The first way to get a streak of five heads is to start with five in a row, from 1-5, and then get a tail, to end the streak. That's a straightforward (.5)^6 = 0.015625. So, the probability that this WON'T happen is 0.984375. We also use this value at the end, to get tails on #95 and then heads from 96-100. So, the probability that this
won't happen at the beginning or the end is the product, or 0.96899.
For all the other streaks of five, beginning with 2-6, we have to
precede and follow the streak with a tail, to define the beginning and the end. So, each streak of five heads starts and ends with a tail, and we have (.5)^7 = 0.0078125. And for it NOT to happen is 0.9921875. How many times? Well, starting with beginning with #1 a tail, then five heads, and #7 a tail, and ending with beginning with #94 a tail, the next five heads, and then #100 a tail. In all, 94 of them. And (0.9921875)^94 = 0.4784. Don't forget the two end streaks, above. So we multiply: (0.4784)(0.96899) = 0.46357. So that's the probability of not getting ANY streak of EXACTLY five. One minus that would yield 0.53643. But, clearly, that's too low and doesn't jibe with the calculators' values of 81% or 82%. Why? Because we haven't included any and all streaks of six, seven, eight, or more. They add more probability!
So, you see how tedious it becomes. We now need to repeat the whole process I just did for five in a row and expand it to six in a row. And when you do that (try it, for fun) and get how much more to add to the above, you get a great deal closer to the 81% or 82% given by the calculators. There's so little left for streaks of seven or higher, that you're almost all the way there by just doing streaks of five and six. Do you understand the process?
Anyway, calculating streaks is NEVER what people think it is, and there is no straightforward algebraic way to do it.
Enjoy!
Don