Some background on short circuit evaluation (skip this if you already know what it is): Examine this if statement with a logical OR operator: If there is short circuit evaluation(“SCE”), as long as the leftmost condition fulfills, the entire if OR statement fulfills and passes control to the next line. If there is no SCE, … Continue reading
Keeping things trading related, many a times you will come across in a forum, or a publication, or been advocated to by another person, a technical system where a whole bunch of charts are shown how a setup is ideal for predicting the following profitable price movement. A highly compelling story of its success is painted by … Continue reading
Here’s some simple plots of the EURGBP spread during the course of a day. Initially tried to use Excel but R handles it much faster and leaner. You can evidently see the spikes during news releases and a general increase as the liquidity drops during the Asian hours. 2012-10-07, 2012-10-14, 2012-10-21 are Sundays. Green line … Continue reading
I spent the better part of yesterday figuring out where I might have accidentally written an infinite loop. Reason being that the moment I started my backtest, MT4 would crash upon accessing the EA. It seemed the most plausible explanation and I went about combing through every new line. What I couldn’t rationalise was that … Continue reading
This is a very simple trade management EA that will close all your Open Orders (or both Open and Pending Orders) when your drawdown against balance exceeds a set percentage limit. E.g. Balance = $10,000 and “DrawdownPercent” is set at 2.0, if floating P&L is greater than -$200.00, all Orders will be closed. A simple … Continue reading