To develop and back-test trading algos its essential to have great gobs of historical data on hand, almost always at the tick level. More often than not this data comes from your broker—OANDA, Alpari, DukasCopy, and Integral (TrueFX), to name a popular few—whether through commercial platforms like MT4 or proprietary APIs. Alternately, one can use a generic downloader like Birt’s Tick Data Suite.
Over the years I’ve worked with more than a dozen brokers and other data providers so you think I’d have a handle on this stuff by now, but nothing could be further from the truth. No, its an ever changing and messy landscape. Continue reading →
There are countless ways to chart price movement (interval or tick-count-based candlesticks, range-bars, Kagi, etc.) but my hands down favorite is Renko. Well, not Renko, per-se, but rather a Renko variant I like to call “Wicko.” Renkos track fixed price movements irrespective of time, which is super useful if you want to filter out noise. Unfortunately, a traditional Renko only includes Open and Close prices; not High’s and Low’s.
As to why I bothered to create my own Wicko feed (or to use the QuantConnect term: consolidator), I couldn’t find a single bug-free C# implementation even though I spent something like four hours looking. There are plenty of contenders, of course—the internet is rife, after all, with iffy code!—but each and every implementation had one or more obvious bugs. The rounding errors and lack of edge-case handling were the least of it, but the deal-breaker was the marked ignorance of gap handling.
Dare I say, my own implementation handles things beautifully, proved out by a bunch of unit tests. You can download the source from my GitHub repository.
BTW, the name Renko come from the Japanese term for bricks: renga. I’ve always liked the notion of laying down bricks on a chart, so that’s another reason to love ’em.
A line from Jackson Browne’s excellent song “The Road” keeps running through my head: “You forget about the losses, you exaggerate the wins.” While often true in life, I’ve found this to be especially true in trading. Indeed, I’ve only met a mere handful of traders who excel at record keeping. The irony, of course, is that it’s literally insane to be a trader and do otherwise; sort of like swatting at an overpriced piñata that they keep on moving out of reach.
Continue reading →
Inasmuch as this is my very first post, you might expect me to take the opportunity to lay out a cogent well-reasoned plan of action, maybe even the raison d’être for foisting my blather on the world. I’m not going to do that, though, since the entirety of my plan is to have “no plan.” With that said, I do hope to start a conversation with a tiny fraction of the population. My intended audience: those few individuals who are both interested in automated trading and have the wherewithal to design, develop, or otherwise participate in the fabrication of such systems. I’ll consider this blog to be an outrageous success if it introduces me to a mere handful of them.
To give a quick bio that omits most of the essentials, I was born and remain—for the present—very much alive. More to the point, I spent a good part of the preceding 12 years writing custom automated trading systems, historical tick-data feeds and repositories, technical-analysis agents, order-management systems and services, and trade visualization tools. I also wrote six different FIX-protocol trading libraries from scratch. Then, to cap things off, I ran countless simulations. By countless, I certainly mean a number in the low millions, although I might be underreporting things by as much as a full order of magnitude. To put things in perspective, a typical run would iterate five or six ranged parameters against three years of tick and/or bar-level Forex data, using self-tuning genetic programming-based AI frameworks. The simulations typically ran on four desktop-grade PCs, although in the last year or so I’ve taken to running simulations in the Azure cloud.
Having delivered myself of an exceedingly long mouthful, I’ll have to leave all of the interesting personal bits for another post. In the meantime, welcome!