When is a System NOT a System

When the system is being openly discussed or sold on the Internet. I can think of no better way to negate the utility of any of my systems than by discussing them with others.

And if I had a system that didn't make any money then selling it would be the only way of increasing its utility, which is the only reason I can think of for selling a system.

By all means discuss the mathematics of your system, if you don't understand something yourself. But make sure you don't give away the workings of your system.

Visit any of the many gambling forums and you will see beginners announcing a wonderfully simple system that is going to make them rich. Only to have it shot down in flames by someone who understands probability theory.

Online poker brought thousands to the Internet, believing they were going to get rich. That spawned websites for people to discuss strategy (thus negating the strategy's utility) and then came the software (The Head Up Displays) to give you an edge over everyone else.

Likewise the betting exchanges have brought thousands to the Internet who think they are going to become expert traders. They get the software, put money into their account and then lose it.

You need a solid base of probability theory to understand why that wonder system doesn't work. Learn how betting markets work and how they are bounded by the overround.

Arbitrage tells you why prices don't behave the way you want them to, otherwise we would all be rich.

Get spreadsheet software to test your theories. Make models of when it all goes wrong! just as much as when it all goes right so that you understand the downsides.

Above all, keep your systems to yourself otherwise anyone you share your system with will share your potential profit with themselves.

KISS - Keep It Simple Stupid

One of the first lectures I remember from my days at university was a tutorial in which the professor introduced me to the KISS principle.

My professor's Canadian accent still resonates around my skull. "Keep It Simple Stupid, he said and I have never forgotten those four words.

Essentially, the more complicated you make a trading or betting rule the less it gets used and the more chance it has of failing or not doing what you expect it to because of variance.

Occam's razor states that something should be as simple as possible but no more so. Start with a simple hypothesis and test its validity. If it doesn't work then forget it.

Build upon your learning, step-by-step and introduce new knowledge incrementally. Don't assume you can crack any problem in one go.

I have been working on betting markets since I was a child. Numbers have always fascinated me. Now, in my forties, I am still learning new things.

Each day I try to go to bed having learned one new thing. I set my self goals and create simple tasks to get me closer to those goals. There is no legal way to get rich quick. Even a bankster gets caught, eventually.

I have a stack of scrap paper on my desk and I am constantly doodling ideas. I test those ideas statistically and programatically such as with Monte Carlo methods.

Systems are tried in "practice mode" and when I am certain that I have an edge then I trade with that new system, keeping things as simple as possible.

Markets move fast and simplicity gets you in and out of the market with a profit or a small loss. Over-thinking leads to panic and big losses. Your research needs to be systematic and your order execution too.

A simple strategy will 'fire' more often than a complex one and so there will be more data to test it with. My best trading strategies are amazingly simple and so they fire many times a day and create a lot of data to evaluate. I can then set my profit taking and stop loss levels correctly and lock in a nice edge.

Keep It Simple Stupid!

Predicting the Starting Price is NOT Possible (for us mortals)

Before the creation of betting exchanges, whereby you can lay as well as back a horse, gamblers were limited to placing bets with a bookmaker. These bets were win bets with no possibility of laying off to take a profit, prior to or during the race. The only way to turn a profit would be to find a "value bet", a bet whose price is greater than the true price for that horse.

To find a value bet professionals create their own forecast (or tissue) prices. This forecast is what professionals believe will be the price of each horse just as the race starts. As we know from efficient market hypothesis, the starting price (SP) represents the true probability for a horse to win. If at anytime before the race starts, the price of a horse to win is greater than the forecast price then a bet will be placed. The reason being that SP will be the true probability of the horse winning and any price taken above that would be a value bet.

The problem with this system is that between creating a forecast price and the race starting, new information can enter the market thus altering the crowd's perception of the race's outcome and the probability of a horse winning. Any attempt at forecasting starting prices does not take into account new information and will therefore not predict SP. New information, entering the market, changes the eventual SP and so any forecast will be incorrect.

So how do the professional bettors make money? Simply, they have prior access to the new information entering the market. Insider dealing exists in sport, just as much (if not more) as in financial markets. You may have heard the term "connections" being used in horse racing. Connections are links between various people associated with a particular horse. A professional may have contacts within a training yard and will have access to information that only owners and trainers have access to. This information can be factored into the professional's "forecast".

For example, an owner might hold a horse back for a few races to create the impression that it is not so good. In that way a future race will provide odds big enough for a "betting coup", whereby the professional can profit from the mis-priced winning horse. Professional horse racing bettors are insider traders and are not to be confused with professional gamblers. Although a person may be both, a professional gambler is not necessarily a professional bettor in the horse racing world.

Patrick Veitch is an excellent example of an insider trader/professional horse racing bettor. He owns horses so he can directly influence a market. He tells other trainers how to race their horses (thus gaining inside information). Patrick often gets involved in betting coups whereby horses are mis-ridden to throw the bookies before a large bet is distributed (via his many bet runners) in a future, favourable race. It's no wonder Patrick's profit margins are so big. Betting your own horse to win (at favourable odds) is always more profitable than the prize money received from owning a horse. Odds manipulation is the way to do it. Is all of this legal? Not in the financial world but then the 'Sport of Kings' abides to a different set of rules.

Rateform

Following on from the previous article about The Punter's Revenge, I am reminded of ratings for football games. Mentioned in The Punter's Revenge Rateform is a ratings method borrowing from the chess world's Elo rankings for chess players.

The system was called FRAN (Football Rating Assessment Number) and is continued to this day under the name of Rateform.

Rateform works in the following manner.

  • Initially, the ratings system assigns the same number of points to all teams in a particular league division. Over time points are redistributed between the teams, the better teams gain points and the not so good lose points. Over all the average points for each time remains the same.
  • For each match played, the home and away team contribute a fixed proportion of their ratings points. It is generally accepted that the home team contributes slightly more as it has more to lose by not winning and the away team has more to gain from an away win.
  • The winning team takes all the points contributed. However, if the game ends in a draw then the away team gains the difference between the slightly larger amount of points the home team contributed.
  • For the home team, winning is important. Even a draw will result in the lowering of the team's rating.

Other ratings systems, based solely on say the number of goals scored in the last few games do not take into account the relative strengths of the teams. Scoring an away goal at Old Trafford is a lot more important than scoring away at the ground of a team less accomplished than Manchester United.

Over time Rateform ratings settle down from their initial starting values and become quite representative of the chances of one team beating another.

Also the values you assign to the number of points contributed by the home and away teams is optimisable. Generally, it is thought that the home team should contribute 7% of its rating and the away team 5%. But with the ratings you can perform a statistical survey and reoptimise these percentages, if you so wish.

We can also have different values depending on whether the game is a local derby, in the winter, dependent on crowd attendances, a vital or not so vital end of season game etc. The list of optimisations is endless.

Example Usage

Generally, Rateform starts with all teams being given 1000 points. When teams meet the home team contributes 7% and the away team 5%

Home Team - 1000pts
Away Team - 1000pts

Pot = (7% of 1000) + (5% of 1000) = 120pts

Result - 1-0 to home team

New ratings

Home Team - 1050pts
Away Team - 950pts

(average is still 1000 points per team)

Conclusion

As you can see, we now have ratings that can be tested. For example, if a team has a 200 points advantage or more, we can statistically test how many times such a team wins and by how many goals.

We can use these statistics to judge how good the rating system is and if it needs modifying. Our statistics will also give us a win probability that can be matched against odds being offered to determine if there is an edge over the market that is worth betting on.

Rateform has now been superseded by newer methods, which can be found in Who's #1?: The Science of Rating and Ranking

The Punter's Revenge

Here's an old book from my shelf, The Punter's Revenge. I must have bought it a good twenty years ago, as can be seen from its condition. A well-thumbed read whose binding is coming loose.

I first came across evolutionary computation when I attended a lecture in 1987. The lecturer mentioned BEAGLE (Biological Evolutionary Algorithm Generating Logical Expressions), which I attempted to replicate on a ZX Spectrum with limited results.

Later, in my PhD I contacted one of the authors, Tony Drapkin, to talk about all things horse racing. I must contact him again to see what's new after all these years. The book contains information on statistics, bookmaking, prediction of horse races and football games. There is plenty of BASIC code, originally for the BBC Micro but all easily portable. There is also mention of other gambling propositions such as roulette and poker.

Due to the book's age there is no mention of betting exchanges just fixed odds and pools coupons. Still, there is plenty in the book for the beginner.

You can still pick up a copy on Amazon - The Punter's Revenge

Write Your Own Betfair Software

In addition to trading via Betfair's website, Betfair also permits access to its servers via an API. Access to Betfair's API is free of charge but there are limits to the amount of data you can download at any one time. Betfair has replaced its old SOAP based API-6.0 with API-NG, based on JSON. My first impressions are that this is a much easier API to understand and code to. I have coded API-NG applications quite easily by myself without help from others, unlike the previous API.

Programming for Betfair, a guide to creating sports trading applications with API-NG, teaches you how to program a complete application for trading on Betfair. Also included is the building of databases for offline analysis, automated Betfair charts and discussion on advanced trading techniques. (Click here for the contents.)

Automatic Exchange Betting covers the now defunct API-6.0 but it does go into detail about the construction of an automated trading system. The book also covers using odds lines, weight of money, average prices etc with which to build trading systems.

Another book that details the construction of an automated betting system is Calculated Bets: Computers, Gambling and Mathematical Modeling to Win. Written by Professor Steven Skiena, Calculated Bets details the professor's successful modelling Jai Alai matches, developing a trading strategy using Monte Carlo methods and then implementing bet automation.

The Benefits of Writing Your Own Software

Most third-party trading software is licenced. You will have to pay a monthly fee to use the software. Obviously, that is not the case when you write your own software.

If you have an idea for a trading algorithm that cannot be implemented by current third-party trading software then asking them to add the required functionality might alert them to what your trading algorithm does. Third-party trading vendors are usually traders too. Don't give them your ideas.

During the early days of financial algorithmic trading, banks would buy trading software from other companies. Some of these companies ran logging software that would read what a trader was doing and then front-run that trader's order. That is not to say that any third-party sports trading software vendor is reading your keystrokes for data mining purposes but if you write your own software then you can be sure that your actions are not being mined.

Designing Your Trading Software

Rather than trying to code the ultimate trading platform straight away, you should first build simple single-task tools to handle repetitve tasks. You can then add your own metrics for manipulating Betfair data. After that you might want to automate betting and position tracking. Finally, you can code a bot that does all of the above whilst acting under your own trading rules. My own trading system is a hybrid, with automation of many tasks but the final decision of when to trade is with me.

Level Stakes Betting

I don't recommend level stakes betting. You will hear it said, "A system that can't make money at level stakes is a losing system." That is correct but it is hardly going to make you wealthy. Level stakes success is just another way of saying, "My system statistically picks more winners than losers."

Would you bet level stakes if someone promised you inside information? Of course not. If a cricketer has been bought by a syndicate to throw no-balls and you are a member of that syndicate, then you are going to bet every last penny that you have.

Level stakes is just a pencil and paper exercise to test if your system works or not. In fact, you don't even need to pretend that you are staking anything, level or not. Just do the maths, prove your system works and then look through your statistics for your edge over quoted odds. Use that edge as described in Kelly Criterion to place your bet. Maximise your return!

See also -  Money Management

Money Management

A good trading system can be ruined by bad money management. I see a lot of bad money management systems, one of which is Fibonacci Staking. You won't see Fibonacci mentioned in financial literature with relation to money management. If you mention it then expect to be laughed at.

Another system that you may have heard of is the Martingale system, an 18th century invention to "help" a bad gambler get his money back. After losing a bet, the Martingale gambler doubles his next bet to get a return that covers the winnings of the current bet and the loss of the previous bet. The problem with the Martingale system is that if the gambler is on a losing streak then doubling up soon encompasses the whole of his bankroll. If the bad gambler loses again then he is penniless. Casinos have a maximum table stake so a Martingale gambler won't even get the chance to place a large enough bet to cover their losses so you can ignore all those YouTube videos promising you how to get rich quick playing roulette.

A Fibonacci staking plan is not much different to a Martingale. The stake is not doubled but increased by the Fibonacci series, where any number in the Fibonacci sequence is the sum of the two previous numbers.

The Fibonacci series - 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55 ... and so on

Again a losing streak will soon ramp up the size of your bets and eventually require a bet greater than your bankroll (or table maximum if you are in a casino). You will last a little longer than a Martingale gambler as you are not quite doubling up but not for much longer. If your system is a losing system then all that Fibonacci or Martingale betting will do is help you to lose your money more quickly.

The problem with Martingales (and derivatives such as Fibonacci) is that the stake bears no relationship to the probability of the event being gambled upon. There is no relationship between any two separate sporting events that yields a Fibonacci series or any other series. As we know from Kelly Criterion and its underlying information theory, a gambler should always bet in proportion to their certainty. A gambler with 100% certainty should bet their house, regardless of what their staking plan says. Of course, a one horse race is never run.

Anything gamble less than a 100% certainty must be judged against the odds being offered. This is where you look for your edge (See Kelly Criterion). If there is no edge then you keep your money in your wallet. Offered evens on the toss of a coin, the intelligent gambler does not bet unless the coin is biased towards his chosen head or tail.

Another fact, derived from Kelly Criterion, is that you should decrease your stake after a loss and not increase it. You should only increase your stake after a win. In other words, chase your winnings because you have more money to risk and never chase your losses. All this should demonstrate to the intelligent gambler that a staking plan that is not based on edge is doomed to fail. 

Because you lost your last bet, why should the certainty of your next £55 bet be related to the previous £34 just because 55 follows 34 in the Fibonacci series? Fibonacci staking smacks of superstition and that a losing gambler has read a New Age book on the magic of the Fibonacci series and thinks it can cast a magic spell over a probabilistic event. Poppycock!