# AnalyticBridge

A Data Science Central Community

# Are Lottery Winning Numbers Really Random?

Most analytic people would agree that lottery is a tax on the innumerate. However, for this statement to be true, we need to assume that winning numbers (and any combination of digits from these numbers) are truly random. If not, of course smart people are going to find and devise algorithms to increase their odds of winning, and/or will try to sell their magic "winning numbers" to idiots.

Big question: Has anyone ever tested whether the winning numbers, for popular lotteries, are truly random or not? And how / what kind of tests would you use to determine randomness?

Not so big question: What if you start a lottery where winning numbers are NOT random, allowing smart people to detect patterns and increase their chances of winning? Operating a lottery business is highly illegal (worse than rape or murder, although it is a victim-less crime), but if you change it to a game where winning numbers follow some patterns (e.g. they are 12-digit prime numbers exclusively), then it might not be illegal anymore, as it is no longer a game of chance, but instead a game of intelligence - a bit like stock market gambling.

In any case, see below winning numbers for the Florida lottery. Do you see any pattern, or do the numbers truly look random? Can you come up with an algorithm that increases chances of winning, based on these numbers (back-testing, cross-validation required to answer the question, but the data is here for you to explore).

Related articles:

Florida Lottery Results
 From: MON 10/24/11 Thru: WED 11/23/11
 `SAT 11/19/11` 09-16-17-28-30-11 PP: 3 `WED 11/16/11` 13-22-25-39-51-28 PP: 2 `SAT 11/12/11` 04-35-36-51-56-08 PP: 5 `WED 11/09/11` 05-35-57-58-59-12 PP: 3 `SAT 11/05/11` 02-33-39-40-43-26 PP: 3 `WED 11/02/11` 12-14-34-39-46-36 PP: 4 `SAT 10/29/11` 11-16-40-51-56-38 PP: 5 `WED 10/26/11` 01-18-21-39-55-06 PP: 3
 `SAT 11/19/11` 03-05-17-24-34-53 `WED 11/16/11` 10-24-34-37-39-45 `SAT 11/12/11` 03-11-15-22-37-38 `WED 11/09/11` 09-16-29-44-48-51 `SAT 11/05/11` 01-04-05-37-38-51 `WED 11/02/11` 11-31-34-39-47-52 `SAT 10/29/11` 03-08-12-28-34-48 `WED 10/26/11` 02-12-13-27-48-50
 `SAT 11/19/11` 05 `WED 11/16/11` 04 `SAT 11/12/11` 02 `WED 11/09/11` 04 `SAT 11/05/11` 05 `WED 11/02/11` 03 `SAT 10/29/11` 03 `WED 10/26/11` 04
 `TUE 11/22/11` 02-09-28-29-35 `MON 11/21/11` 03-04-17-27-29 `SUN 11/20/11` 10-21-27-28-29 `SAT 11/19/11` 08-15-18-33-34 `FRI 11/18/11` 01-04-16-29-30 `THU 11/17/11` 09-11-24-26-28 `WED 11/16/11` 08-22-27-32-33 `TUE 11/15/11` 01-02-08-21-23 `MON 11/14/11` 12-16-20-21-24 `SUN 11/13/11` 01-14-21-25-34 `SAT 11/12/11` 12-14-21-28-35 `FRI 11/11/11` 17-18-19-24-36 `THU 11/10/11` 01-17-18-26-31 `WED 11/09/11` 02-05-15-29-31 `TUE 11/08/11` 03-06-09-19-28 `MON 11/07/11` 07-09-20-22-28 `SUN 11/06/11` 02-10-12-15-28 `SAT 11/05/11` 10-23-26-28-36 `FRI 11/04/11` 09-16-26-32-33 `THU 11/03/11` 03-11-15-24-36 `WED 11/02/11` 10-18-24-31-34 `TUE 11/01/11` 04-07-19-21-22 `MON 10/31/11` 06-23-28-30-34 `SUN 10/30/11` 02-06-09-25-32 `SAT 10/29/11` 06-14-19-21-26 `FRI 10/28/11` 01-07-18-22-28 `THU 10/27/11` 06-12-17-18-22 `WED 10/26/11` 03-05-10-17-31 `TUE 10/25/11` 07-15-21-27-35 `MON 10/24/11` 11-12-17-31-33
 `TUE 11/22/11` 05-18-22-43-21 `FRI 11/18/11` 11-12-28-39-12 `TUE 11/15/11` 03-04-12-35-13 `FRI 11/11/11` 04-15-19-42-04 `TUE 11/08/11` 12-35-37-38-21 `FRI 11/04/11` 03-10-16-26-13 `TUE 11/01/11` 02-06-28-37-22 `FRI 10/28/11` 06-09-18-25-19 `TUE 10/25/11` 10-20-38-43-06
 `WED 11/23/11` 2-6-1-3 `TUE 11/22/11` 5-3-9-4 `MON 11/21/11` 4-3-6-7 `SUN 11/20/11` 8-2-5-9 `SAT 11/19/11` 4-8-3-3 `FRI 11/18/11` 4-8-5-7 `THU 11/17/11` 0-6-7-7 `WED 11/16/11` 1-5-2-1 `TUE 11/15/11` 3-8-6-8 `MON 11/14/11` 9-2-9-9 `SUN 11/13/11` 0-3-4-6 `SAT 11/12/11` 2-7-1-2 `FRI 11/11/11` 6-7-3-9 `THU 11/10/11` 4-6-8-7 `WED 11/09/11` 0-6-1-7 `TUE 11/08/11` 1-2-6-4 `MON 11/07/11` 6-4-6-3 `SUN 11/06/11` 7-6-6-0 `SAT 11/05/11` 8-1-7-0 `FRI 11/04/11` 7-8-2-3 `THU 11/03/11` 0-6-5-4 `WED 11/02/11` 2-3-8-1 `TUE 11/01/11` 8-3-1-9 `MON 10/31/11` 0-3-6-1 `SUN 10/30/11` 4-7-9-2 `SAT 10/29/11` 6-0-5-6 `FRI 10/28/11` 6-0-1-1 `THU 10/27/11` 9-2-0-7 `WED 10/26/11` 5-3-1-7 `TUE 10/25/11` 1-5-2-9 `MON 10/24/11` 6-8-4-5
 `WED 11/23/11` 2-0-9 `TUE 11/22/11` 6-7-1 `MON 11/21/11` 0-6-7 `SUN 11/20/11` 9-0-3 `SAT 11/19/11` 8-2-0 `FRI 11/18/11` 5-7-7 `THU 11/17/11` 3-1-4 `WED 11/16/11` 2-7-4 `TUE 11/15/11` 3-7-2 `MON 11/14/11` 1-0-2 `SUN 11/13/11` 0-2-0 `SAT 11/12/11` 4-8-8 `FRI 11/11/11` 4-6-8 `THU 11/10/11` 2-0-1 `WED 11/09/11` 6-9-9 `TUE 11/08/11` 7-0-6 `MON 11/07/11` 8-9-1 `SUN 11/06/11` 3-4-3 `SAT 11/05/11` 9-9-0 `FRI 11/04/11` 4-5-2 `THU 11/03/11` 5-0-4 `WED 11/02/11` 9-8-8 `TUE 11/01/11` 8-1-9 `MON 10/31/11` 7-5-6 `SUN 10/30/11` 0-9-9 `SAT 10/29/11` 2-6-6 `FRI 10/28/11` 1-8-4 `THU 10/27/11` 6-5-6 `WED 10/26/11` 0-4-5 `TUE 10/25/11` 1-9-7 `MON 10/24/11` 2-2-3
 `WED 11/23/11` 7-2-4-5 `TUE 11/22/11` 5-6-5-1 `MON 11/21/11` 5-5-3-1 `SUN 11/20/11` 2-4-1-8 `SAT 11/19/11` 6-1-3-1 `FRI 11/18/11` 1-1-7-2 `THU 11/17/11` 0-9-0-2 `WED 11/16/11` 0-6-1-8 `TUE 11/15/11` 6-9-0-2 `MON 11/14/11` 3-3-7-7 `SUN 11/13/11` 6-6-7-8 `SAT 11/12/11` 9-8-3-1 `FRI 11/11/11` 1-1-7-9 `THU 11/10/11` 4-0-2-8 `WED 11/09/11` 4-0-3-3 `TUE 11/08/11` 9-0-6-0 `MON 11/07/11` 3-1-8-4 `SUN 11/06/11` 6-1-2-8 `SAT 11/05/11` 6-5-8-6 `FRI 11/04/11` 7-8-5-1 `THU 11/03/11` 3-3-3-7 `WED 11/02/11` 0-3-4-1 `TUE 11/01/11` 5-9-1-7 `MON 10/31/11` 3-8-2-9 `SUN 10/30/11` 0-8-1-8 `SAT 10/29/11` 8-5-4-3 `FRI 10/28/11` 5-3-3-3 `THU 10/27/11` 1-9-1-8 `WED 10/26/11` 2-1-9-1 `TUE 10/25/11` 7-7-0-7 `MON 10/24/11` 4-6-4-8
 `WED 11/23/11` 5-6-5 `TUE 11/22/11` 5-1-8 `MON 11/21/11` 9-8-0 `SUN 11/20/11` 7-7-6 `SAT 11/19/11` 6-8-9 `FRI 11/18/11` 3-0-7 `THU 11/17/11` 9-3-2 `WED 11/16/11` 2-1-4 `TUE 11/15/11` 5-6-1 `MON 11/14/11` 7-4-4 `SUN 11/13/11` 8-2-9 `SAT 11/12/11` 5-5-8 `FRI 11/11/11` 2-1-1 `THU 11/10/11` 4-1-6 `WED 11/09/11` 7-1-1 `TUE 11/08/11` 2-0-8 `MON 11/07/11` 4-3-4 `SUN 11/06/11` 3-0-4 `SAT 11/05/11` 0-9-1 `FRI 11/04/11` 8-2-6 `THU 11/03/11` 6-3-8 `WED 11/02/11` 9-4-4 `TUE 11/01/11` 9-5-2 `MON 10/31/11` 5-9-5 `SUN 10/30/11` 2-7-9 `SAT 10/29/11` 5-4-4 `FRI 10/28/11` 1-8-7 `THU 10/27/11` 8-0-9 `WED 10/26/11` 3-7-9 `TUE 10/25/11` 9-2-3 `MON 10/24/11` 5-6-9

Views: 78067

Comment

Join AnalyticBridge

Comment by Vernon Sanderson on May 20, 2017 at 5:15pm

There are those that argue, and I tend to agree, that roulette is random and can’t be beaten with any roulette system or strategy.

Comment by Tony Nolan on June 17, 2013 at 6:34pm

These post emphasis the issues that many people have in dealing with analytics, by the people who actually do it.

For instance, Randomness does not occur in the physical world. There is always a cause and effect, however we have difficulties getting observations and data at the desired levels to explain everything we need to.  So why would you apply some thing that does not exist to examine a process that does, apart for a sampling experiment.

So, your not playing the game to beat the machine, your playing the game to beat the people who designed the game in the first place. So, assuming we are talking about ball dropping Lotto games, the odds are designed to limit pattern recognition. There is also a limitation on pricing the number of picks to successfully gamble for a win.

So if you want to increase your chance of picking the correct numbers, you have to;

1. break down the factors that effect the mechanics of the game.

2. increase your odds of wining by controlling, understanding specific, and or reducing factors.

3. finding the best way spread the bets to cover the desired number of sequences.

4. use data analysis to drive the output, over a long history

5. make sure to use feedback into the model

6. make sure that you dont follow what the game makes idea of being a winner, set your aim on some thing else.

If you change the rules of game play, then the game owners risk adverse activities can be reduced to your favor.

While I am writing a paper on it at the moment. I can usually get 4 or 5 numbers out of 9 each draw in an Australian Lotto game. And I dont even really try that hard. Im not sure where I would publish it, but I can add in the link, if any one is interested.

Comment by Javier Alonso on June 13, 2013 at 3:34am

I did the following with the results of Spanish "Lotería Primitiva", a 6/49 lotto running since 1985:

1. Generate a file with all the possible results, from 1,2,3,4,5,6 to 44,45,46,47,48,49. (13.983.816 entries, all the combinations of 49 numbers taken in groups of six without replacement)

2. Convert the results to a binary number: 1,2,3,4,5,7 becomes 101111, etc.

3. Convert binaries to integers. Not very surprising, they form an almost Benford list. Numbers starting with 1 are about 30%, etc.

4. Do the same with actual results

The actual results show the very same distribution, even with such a small sample (2600 over 14 million)

Should it prove that results are fair?

Comment by Peter Mancini on June 4, 2013 at 4:15pm

There is a better analysis to perform. Examine the level of entropy in numbers in which there were a payoff. Compare that the the number of tickets in which the payoff was divided. My not-always-smart gut says that there will be less entropy in numbers with multiple tickets. My theory is that people use things like birth dates and only certain combinations are possible. Further, people like to spread the numbers around which also reduces entropy. You are better off using a quickpick if you want to maximize your win because high entropy numbers have less chance of having competing tickets to share the take with. I am assuming there is no gain to be had with choosing between a high or low entropy set and that no matter what a ticket always has a 1 in 175 million chance of winning Powerball.

Comment by Vincent Granville on March 29, 2013 at 9:01am

Can you increase your return by purchasing tickets in bulk, and negotiating a discount with the retailer?

Comment by Marcus Emmanuel Barnes on January 9, 2012 at 12:00pm

Hi, Vincent,

I was walking through the SFU Statistics and Actuarial Science department and noticed a paper posted in a display that's relevant to this discussion:

Genest, C., Lockhart, R. A. and Stephens, M. A. (2002), χ2 and the lottery. Journal of the Royal Statistical Society: Series D (The Statistician), 51: 243–257. doi: 10.1111/1467-9884.00315

The authors tested data from Lotto 6/49 (a long-running Canadian-wide lottery) "for the equiprobability of occurrence of such lottery numbers, whether taken individually, in pairs or in larger subsets."  Their general conclusion was that at the time of writing the paper, there was no serious grounds for "suspecting a lack of uniformity in the [Lotto 6/49] results."  There are of course always some subtleties...

Comment by Daniel Lieb on December 21, 2011 at 2:14pm

If the random number generator isn't perfect, it isn't random.  Balls falling from a tube and bouncing in a machine is not entirely different than a croupier shooting a roulette ball.

However, good luck capitalizing on either.

Comment by Thomas Lincoln on December 1, 2011 at 10:01am

There are short term patterns in randomness, just like in outer space where there are random patterns of stars called galaxies, the pattern is mostly circular, the randomness is the location.  The lottery attraction is that the payoff is huge, but a slightly less random betting scenario would be sports, which can have a very large payoff if consistent.  The problem with sports betting is its based upon human behavior, which is its own form of randomness which does not have physical limitations..