Admit Your Mistakes

The only way to progress as a trader is to admit your mistakes and correct them. I've noticed a few more blogs (courtesy of Green All Over's blog list) that have deleted pages they wished they'd never published. You know the type of page I refer to; "The One Month Challenge", "Double My £100 Bank in 10 days", "Make £100,000 in One Year", "This Time Next Year Rodney..." etc. Pages are removed when the bankroll blows up or the website is never updated again.

Bold claims are usually made by young traders starting out with no real idea of how to trade. Well, I am going to start the ball rolling by admitting that I was such a trader, many years ago. I was working in The City and if I wasn't spread betting futures contracts, I was in the casino (after work) playing poker. Internet poker and Betfair had just taken off. I was the quintessential action gambler. All money, bluster and no idea of what I was doing. Money comes easy in The City and goes just as quickly.

When the first third-party software applications came out for the Betfair exchange I was onto it. Of course, the ladder has you "scalping" like a pit trader in a futures exchange but without a structured strategy losses mounted. Any idea I heard of I tried. Even if it failed I just blamed others and continued in the hope that I could make the markets bend to my will.

Then the best thing in my life happened, I was offered a redundancy and so I left The City. I haven't played poker since. I stopped futures trading. Rather futures stopped me when I took a £10,000 hit on an oil contract. I reevaluated my entire life and became more realistic in what I could achieve. I realised that wealth is a pyramid structure with a long hard climb to the top and there is not much room at the top, even if you get there. Try hard but not so hard that you guarantee failure.

Today, I get rich... slowly. If at all. I make a living. I am comfortable. I do not have a wealthy lifestyle. I am a member of a tennis club with plenty of fast cars parked outside. That is the lifestyle choice of other members not me. I am happy to drive a twenty year-old secondhand jeep that I maintain myself.

And so I offer my list of mistakes and ask you to do likewise on your blog and/or Twitter account. Retweet and get others to do likewise. Only by being realistic and truthful to yourself and towards others can you progress. It's the first step to success.

My mistakes...

1) I thought only of winning and not a winning edge.

2) I jumped at ideas and traded them without back testing.

3) I had no money management strategy.

4) I got caught up in the action rather than trading the numbers impassionately.

5) I chased my losses instead of my winnings.

5) I boasted about winnings and kept quiet about losses.

Today, I never trade with trading models that have not been thoroughly tested. I write ideas down on scraps of paper and when the day's trading is over I test those ideas to destruction. Most fail. You just have to accept that fact and move on. I never trade a losing model in the hope that it might work.

Money management is very important to me as I am self-employed. My sports trading is just a part of my income and I have to look after every penny I make. I am far closer to retirement than I am to my days at university. There can be no big mistakes from now on, just little ones to learn from.

I never tell people I know of what I do. If they ask then I just say, "I write and I work with computers." If they ask about my website, book or Twitter account then I just say, "If you are interested in that sort of thing then you will already be reading it." I used to make fun of a Chinese girlfriend who always told me to be "humble and modest" (it was the pronunciation that amused me - humbull and moh-dest) but she was right. Nobody likes a big head and P&L blogs are the worst kind of big-headedness if not written with a large dash of modesty. There are some good P&L blogs and they know who they are because I frequent them but most are egotistical "look at my latest win (whilst we brush the losses under the carpet)".

Action I find on a tennis court. If I have an off-day or just don't feel happy about life then I take it out on a tennis ball and not on the markets. As children we were all told to pick on someone our own size. We are all pygmies in the markets.


Apparently, I am the only person in the world to have made trading mistakes. I never knew I had so much money to pay off all you winners!

Approaching Half Way In New Model Test

I am currently testing a new model to add to my trading portfolio. The test consists of 100 trades at a minimal trade size of £2 to see how it matches the model optimised by a genetic algorithm

You may ask why I am not testing this on paper. The reason being that I am running new code that needs to be tested live and the kind of trading I do is very precise and paper trading does not replicate the same live trading conditions.

Already I have made a few changes. The optimisation suggested a profit take whenever a trade makes 25% yield but I have toned this down to 20%. The stop loss is fine as is. I changed some of the code to keep me better informed but essentially it is similar to the code in Programming for Betfair

This is a hybrid trading model whereby the program analyses all the days races at the same time and flags runners that fit the entry criteria for a trade. A human trader then trades the runner with his discretion in play. At no time is the trader permitted to trade below the limits set by the algorithm. There are some things that computers can't do and there are things that humans can't do either. This method utilises the skills of both.

A few figures from the test...

Average win per £1 traded = 0.15
Average loss per £1 traded = 0.10

Strike Rate = 0.68

Longest Losing Streak = 3 trades (model says 5 over a larger period)

Edge per £1 traded = (0.68 * 0.15) - ((1-0.68) * 0.10) = 0.13 (i.e. 13p per £1 bet)

Total % Yield = 6.25%

Average Daily % Yield = 6.55%

Daily Sharpe Ratio = 1.78 (In other words my reward is greater than the risk taken on.)

I have begun to increase the trade size slightly so that I can experiment with gradually entering money into the market or taking it out. The minimum £2 trade is to reduce risk whilst testing a new model and new code that can accommodate the new model but it constrains trading style.

Trading with this model has given me an idea for another so I will reprogram the genetic algorithm trading rule optimiser to see if there is any edge in the new idea. I shall file a final report when the 100 trade test is over.

Compounding Yield in Sports Trading

The magic ingredient that will give us untold wealth. Compounding. We've all done it when we started out trading. We opened up a spreadsheet and took our first day's yield and compounded it over the next few years. "I'm going to be a millionaire!" we foolishly say to ourselves.

I still run a compounding spreadsheet but not for sports trading. My bank accounts and other regular forms of income are noted each week and a compounded value for the next five years is calculated. This makes sense because a bank account (no matter how little they pay these days), peer2peer and other investments can be more relied upon than sports trading income.

I expect to make 10% per year on my portfolio of investments and other incomes and so I expect to double the value of my portfolio in 8 years time. Why can I not do the same for sports trading? The answer is market capacity.

Just because you are making 10% yield on your trades now does not mean to say that you will continue to yield 10% as your bankroll increases thus allowing you to make bigger trades. There is only a finite amount of money on offer in the exchange.

Compounding your winnings is a similar fallacy to using the Martingale to recoup losses. In Martingale betting, a naive gambler playing roulette thinks they can just double their bet after a loss to get their money back. However, the casino has a maximum bet limit and if you have a run of bad luck then your bet doubling will exceed the table maximum and you'll never get your money back.

To control risk a casino sets a limit as to how much money is in play at roulette. The same applies to market capacity only natural forces determine how much money is in play at any one time. Keep on winning and eventually you will hit the market limit as your bet size increases.

In the case of a naive sports trader, they might imagine there will always be enough money to cover their trades. However, the amount of money available at a given price is always finite. If you want a larger trade then either you have to accept a worse price or you will have to put your own offers into the market to get people to take the opposing view. The danger with that is that you have now become the market and if you are wrong about the price then you will lose edge.

And that's the problem you will have with compounding in sports trading. You are in a money market of finite size with agents who are also trying to maximise their wealth creation opportunities. In early market trading there is not much money in the market. Put too much in and you are the market. Make a mistake and someone with better knowledge (an insider) will destroy your edge. Nearer the start of a horse race or during an in-play sport there will be more money available but time is now at a premium where bad decision making can ruin your wealth.

Even though I recommend proportional and Kelly based money management strategies they usually have to be toned down to allow for noise and combining that with market capacity means that the hoped for geometric growth sometimes turns out to be little better than linear growth. I have created Kelly simulations on a spreadsheet and the rate of increase is astonishing but never realistic. There just isn't enough money in the exchange after a few wins.

You can be almost sure of returns from bank accounts, less risky investments and employment income. That is not the case with higher risk investments and sports trading. Compounding of sports trading income in a market of limited cash and limited opportunity is a fallacy. The successful trader will increase their wealth rapidly at first, if they are any good, but after that growth becomes more linear.

Testing Latest Trading Model

The trading model I referred to a few weeks ago is now in test. The model will be making £2 trades for a maximum of 100 trades to see how the model matches against the optimisation results and the out-of-sample test. Also, it will test out some new code that I have written so I don't want to risk too much in case of program failure. Yesterday saw a glitch where a stop-loss failed to fire and the trade was left to go to expiry whereupon it became a bet... and won. I won't be skewing my analysis spreadsheet with that 1200% return.

A poker playing friend who has gone on to great success at the game once said, after he bad beat me for the umpteenth time, "I'd rather be lucky than good." That's not a mantra I wish to copy in sports trading. Yesterday's good luck could easily have been bad luck so I have rectified the glitch and will take all stop-losses on the chin. Besides, my friend may have his fair share of luck but he is also very good.

I have been discussing the testing of this model over at Trader247. The model is a purely technical pre-start horse race trading model. Nothing is known of the runners, riders, trainers or phase of the moon, just market dynamics, wisdom of crowds and market efficiency. The model is highly selective, placing just a few bets per day rather than firing in many hundreds like some sports trading algorithms.

My aim is to slowly ramp up the trade size, making sure not to reach market capacity, which is very easy at any time prior to the last 15 minutes or so of the pre-start market. A single trade opens the position and then it is closed when a profit-take, stop-loss or start-time is hit. There is no doubling down, Martingales or any desperation to claw back a losing position. Just flat £2 bets with a stop-loss. No rushing in with big bets after a modicum of success, shouting to all, "This time next year, Rodney..."

Caveat Emptor

I have recently discovered that Betfair now charges anyone attempting to create a live AppKey for the first time as of 10th May 2016. Anyone creating the live and delayed AppKey from now on will see a disabled live key for which there is a £299 charge to enable it. If you do not pay the fee then your data will be delayed for upto 60 seconds but betting operations are live. At least you only have to pay the fee once unlike third-party software where the recurring monthly fee will eventually be greater than £299.

Supposedly the fee is to to stop unlicensed commercial use. However, the AppKey you are buying is used to indentify users so rogue users can simply have their access blocked when they try to login with their AppKey.

To summarise...

a) As of 10th May 2016 you will have to pay a £299 fee to access live data through API-NG.

b) Betting operations can be accessed live with a delayed key.

c) Althought the lastpricematched returned by the delayed key might be upto 60 seconds old it will have a timestamp.

For those of us who had created AppKeys before the introduction of the fee or who have paid the activation fee we have have access to two keys; a live one and a delayed one. The live AppKey allows us to use API-NG as normal. The delayed AppKey is for testing purposes; you can place bets in realtime but the data you are receiving can be up to 60 seconds old. New accounts will only get access to the delayed AppKey and will have to pay for the live AppKey.

Here is the official reason for the charge on new accounts.

We have recently introduced an application process for new customers who'd like to use the Betfair API for betting. This is to prevent unlicensed commercial use of the API.

The application process does not affect active customers who are currently using the API (personal customers or Vendors), nor will there be any retrospective charge applied to active customers.

New customers who create a new Application Key are able to use the API with a Delayed Key (which by default now allows betting operations for new API customers) but need to apply and be approved for Live App Key API access before paying the £299 one off fee.

The Delayed App Key has always been intended for use by customers for development purpose and functional testing.

When exactly this fee came in I do not know so you will have to check with Betfair for yourself if you are still eligible for a free live AppKey. The fee cannot be retroactively charged so if you already had account prior to the introduction of the fee then you can be safe in the knowledge that you will be able to access API-NG without having to pay the £299 fee.

No Full Algo-Trading Yet

My algorithms still have a degree of discretionary trading about them. By that I mean the algorithm expects a trade at a certain point but the trade is still executed manually, which permits me to get a better price. It matters not if I miss the boat this way as there is always another trade.

A particular algorithm I have recently developed was done so using genetic algorithm to discover interesting facets and then brute force search to complete the optimisation of the areas of interest. I know that the algorithm provides edge at a certain entry point. However, programming the bot to always trade at that entry means that I miss out on the chance of a little extra profit because sometimes the market overshoots where it is expected to go. Because of this overshoot I still enter my trades manually. 

The algorithm is constantly monitoring every race and tells me when any entry has been met. I then look at the spread and decide if I should hold out for a better price. In effect, the entry tells me the absolute maximum or minimum price to trade at so there is no risk of a bad trade. Some trades will go against me, which is to be expected but I cannot blame bad entries as they have been optimised.

I can see a way of creating another algorithm for automating the process of getting a better price than the entry price so there is a possibility that I can update this particular bot to be fully automated. However, I still like to use my discretion. Even financial trading bots in commercial banks have human circuit breakers to act when they sense something is wrong. After all, an optimisation process can only do what is asked of it and no more.

An Honest Tennis Match

I have no desire to waste my life at a desk (just most of it) and so I have rejoined my tennis club until the onset of autumn. My cycle racing days are long gone. The bikes, tools and other equipment having been auctioned off a few years ago. It was sad to see my Roy Cottingham frame go (hence this article has a photo of my old bike and not me playing tennis) but at least it has gone to a collector. Roy was a local builder of frames and a road racer too who sadly became paralysed, preventing him from racing again. I believe he took his life because he could no longer ride.

I feel as though I should be as active as I can but I can't help being jealous of people who die in their nineties having exercised nothing more than their cigarette lighter and their elbow. If I had that lifestyle then I am sure this website would never have been created due to its potential writer having expired decades ago.

Today, the weather was rather wet and so I went to the local indoor courts rather than my club and played doubles against three pensioners. Being a fifty year-old with arthritis evened things up somewhat so I have no guilty feelings about beating up on those older than myself. Besides, I always get lumbered with the most geriatric of the bunch so I was lucky to end the session 7-5 2-6. The prize, a defibrillation machine was shared by all.

On returning home I found I had twisted a neck muscle but at least my heart will be a quanta stronger whilst I recover, sitting at a desk wasting my life, over the next few days. At least the pain was relieved by a post from Cassini at Green All Over (America's #1 Sports Blog!). It was good that a recent comment of mine on his website inspired another old boy back into action. The sports trader blogosphere will be all the more barren if Cassini hangs up his quill.

I have only one negative thing to say about Green All Over and that is Cassini's habit of quoting you and then adding a few more quotes from other people only without attribution. This creates the impression that every quote in his post was by yourself, which is not the case in today's post, Bold Ambition. Still, it's a good article as are all the posts on Green All Over. And now for a power nap, lasting about 24 hours!