Deadline June

Shock horror

I logged on to IB thinking I had £33.6K in the account. I pulled up the account page and it said £32.2K. After I regained control of my eyebrows I then decided it must be because I'd radically miscalculated the loss on a EUR/JPY trade last week.

I then spent the rest of the evening in a foul mood and managed to start a row with my girlfriend and started hatching a conspiracy theory about a clerk at IB skimming off money from customer accounts.

I logged in just now and the markets are back up (IB has them shut down until 5pm NY time) and my account is back to £33.6K.

I'm really not totally sure what's going on there but either the positions I had on over Saturday are a lot more volatile than I thought or I don't actually understand how IB handles forex trading balances.
 
It could depend on what currencies you hold. Is your money all in GBP?
 
My account's base currency is GBP. But I was short USD-JPY and short EUR-GBP so I had -100,000 USD, +10,000,000 Yen roughly, -100,000 Euro and +80,000 GBP on top of my account balance in GBP plus lots of small change in CHF, AUS & CAD.
 
Yes, correct: that was my suggestion. Be happy with a small edge and systems that don't trade frequently but build many of them. As I said somewhere else, if you have a system that trades twice a month, and build 40 of them, that will give you 80 trades per month, which is 4 trades per day.

It's not hard to build 40 of them, because if the principle is a good one, it will work on many different markets.

So that's answered one of my questions already. Often I find a system that works well enough on just one market but I can't find any way of making it work in other markets, so I decide to ditch the system, and then I think maybe I shouldn't have.

Another issue I have with trading systems is the forward-test results, and how to know whether there were enough results in the forward-test to make it representative, or whether I just need a bigger out-of-sample history to test on. So when I write a system and it only trades twice a month, I usually find it doesn't perform out-of-sample. Probably directly related to the complexity of my system. If it was simpler, maybe an out-of-sample test with only 5 trades would be reassuring. But when the edge is only 50% profitable, more often, it just makes a loss.
 
Tell me about it... I am totally frustrated because I just found out yesterday that probably only half of my systems are good. 20 of them have lost money in their first year of forward-testing.
 
Hmm, that's a set-back. Were the stats totally outside what you expected from the backtest?
 
Well, yes. About 10 out of 40 systems sucked big time. I would have to totally throw them away. But I don't like to throw systems away. I'll keep them, forward test them and see what happens.

The other 20 systems that failed, did not fail so much as to say "they failed". It could be a normal drawdown. Most of my systems, taken individually, have had at least 1 year of drawdown in the 10 years they were tested on.

On a good note, if you used all my systems combined, you would never get a negative year. Furthermore, if you allowed more contracts to the systems with less leverage/volatility (GBL, ZN, GBP), you would make at least 100% a year, I would say. Which is however far from my target of 50% a month. You see, it happened that the worst-performing systems were the ones on the CL, and 1 of those contracts, in terms of wins and losses, is worth as much as 3 GBL, ZN, GBP, which are the ones that performed the best actually. So my stats are corrupted by the fact that I calculate everything allowing 1 contract per system.

Conclusion: the systems still make money, but disappointed me. The reversing methodology only seems to work (great) in forward-testing, but seems to have no validity if I back-test it. Let me know if you don't remember what I mean by "reversing". I've explained it several times on my journal.
 
When I was backtesting futures before concentrating solely on currencies, I set up a volatility-based weighting basket of instruments to allow me to compare them all directly, and in fact I got so used to it, I used to forget I didn't have enough money to trade the whole basket. I had ICE Crude in there which had a daily range of $3000, and the CME Eurodollar which has a daily range of $500. And the DAX was pretty insane at $5000, so I'd have 1 DAX contract, 2 Crudes and 10 Eurodollars.

I remember the reversing methodology, although I don't remember you saying it only works in forward testing and not in backtesting. Isn't that impossible?
 
Here's a summary of my automated trading in the last two years, in chronological order:

1) I automated 40 systems, based on back-testing

2) I decided (July 2009) to forward-test them and record all their trades with live prices from IB (sometimes placing real trades).

3) I noticed, in November 2009, that half of the systems stopped working and I associated this with the change of direction of the US Dollar.

4) In early 2010 I devised a system that reversed next week's signals for these failing systems, based on the fact that this week was overall unprofitable for all 40 systems. The method produced profit for all systems in the next 6 months, until today. See image below for how well it worked. The blue line is non-reversed and the pink line is using the reversing methodology:

FORWARD.jpg

5) Urged by someone else who wanted to trade the reversing systems, I decided to make sure that such reversing method also worked in the 10 back-tested years. And I found out that such a method actually decreased profits by 30%:

BACK.jpg


Now, this could be due to, in order of probability:

1) the method does NOT work and I was lucky to make it work in the past 6 months, and I cannot count on it working in the future.

2) the markets have changed (the US Dollar in fact mostly went down in the last 10 years, whereas now it is going up), and this method will work for the future even though it didn't work for the past.

3) the method works, is sound, and it will work in the future, but it doesn't work in the past because the back-testing disktrading.com data is full of holes, and different from the IB live data. So this would mean basically that all my systems are now trading differently than they were tested, and it can be verified by buying the disktrading.com data for last year and see if in back-testing mode the trades were the same as in forward-testing mode.


In fact I always thought that the most reliable source is forward-testing data because it totally matches real trading. So, in a year or so, if the reversing methodology keeps working, I will use it, regardless of what the backtests say.
 
Funny how reversing reduced profits on all the systems you backtested. Without exception?

It does point towards something to do with a general factor, such as the USD. But does it make sense that the USD trend affects them all?

I would discount your (3). As you said before, there's not that much wrong with the disktrading data.
 
Well, as I said before, the systems that need to reverse signals are only the half of them that don't work in normal mode. Only 20 out of 40 systems need to reverse. The other 20 work fine in both back-testing and forward-testing.
 
I would be happy if I had a strong enough negative signal on any of the indicators I'm playing with at the moment to make it worth reversing them.

I've been playing around with these pivot points for days now and I can't get any better performance than I found on the first day, despite coming up with what I thought were some pretty good ideas.

Man, I wish I had a proper newsfeed. What's making the Euro plummet like this? Luckily I was short - and even more lucky, it was within 2.5 ticks of my stop a couple of hours ago.

Anyway, I'm trying to improve what I'm trading - pretty basic pivot points on the Euro. In terms of improvements, what I'd like to see is the method working on more currencies than just the Euro, but as I said, whatever I do either doesn't work or only shows a profit with such a low trade count that it's virtually untradeable - for me at least.

OK, well I'm being a bit of a perfectionist here, I suspect that I might be able to trade one set-up that I got. Over the backtest of 10 years, it trades 3800 times but on a 30min timeframe in 10 markets - that's 1.5 trades per day - so one trade every 7 trading days per market on average.

And on 30min bars! Rats, it doesn't make sense, especially if the portfolio equity curve looks like a roller coaster.

And I haven't done an out-of-sample test on it either.

I have to ask myself, was it worth spending so many days tinkering?

I played with parabolic stops and couldn't get any improvement over the static stop / target exits. I thought I came up with something good doing some exit method development using random entries, but the great exit method for random entries was rubbish for the pivot point entries.

I filtered it using an MA - only entering in the direction of the overlying trend, but that was pants.

I filtered it with a volatility filter and found that it was only improved when volatility was rising. Counter-intuitive I thought, and not that significant anyway.

I filtered it with a measure of the number of straight days in a row in one direction - thinking long clean runs at this timeframe would be a sign that the market's collaborating with the technical analysis. No chance.

I measured the distance between the pivot points on either side and averaged them over 13, and filtered only signals where the distance from the pivot to the current bar was greater. No dice.

I measured the average distance from the pivot point to the entry over 13 pivots and only entered when the distance at this signal was greater. No deal.

Plus of course I combined them all in different ways. Still no decent result.

And now, I've actually lost the code that produced the profitable result so I'd have to go through all this backtesting again to find what it was.
 
I couldn't get the pivots to work from an automated point of view. But I believe - with a good enough programmer and perfect forex data - they would produce money on the EUR forex. I saw them bouncing on the EUR forex (not the future) too often for it to be a coincidence. But I can't even dream of programming this, because it's too complicated. You know, it's a matter of few ticks, so your data has to be perfect. If I tried doing this, it would be like performing surgery on a moving car.

The way I'd go about it is:
1) if price is somewhat oversold, and we touch a pivot point on our way down, insert a bracket order and exit half way to the next higher pivot (with a gain) or half way to next lower pivot (with a loss).
2) viceversa for a short trade.
 
Why do you say it's a matter of a few ticks? From my understanding of pivot points, they're when the high price is greater than the high price of the four previous bars, and greater also than the high price of the subsequent two bars and the opposite for a support pivot.

The mechanism I adopted is just to go short after a resistance pivot, and long after a support pivot, and then to put the stop at the pivot for a loss, and to aim for a target the same distance in the other direction.

What do you mean by 'touching a pivot on the way down'? You use previous pivots as the target?

I guess it's a matter of the difference between programming in a spreadsheet and programming a script.
 
Here's the combined equity curve for the low frequency pivot point system on 9 currencies - I always look at 10 but EUR-CHF performance here was outrageously bad, an order of magnitude worse than the other 9, so I ditched it. I include 3 currencies that weren't profitable over 10 years after transaction costs, but aren't so bad. So shall I trade it? Hmmm.
 

Attachments

  • MyHTML1.gif
    MyHTML1.gif
    9.4 KB · Views: 172
1) On the way down:
from a higher level of price to a lower level of price.

2) difference of a few ticks, requiring surgical precision:
If you don't have the right forex data you'll come up with the wrong pivots (and top of it you're measuring pivots on forex and you're trading futures which further complicated things)

3) using a pivot line as a target level:
As I said, I (would) use it a both a loss and target level ("bracket order"), but not from a pivot line to another, only half way, which means between the two lines.

Yes, I use code to program and back-test: I don't do back-testing in a graphical way. Nor would I automate such a system in a graphical way. I am always talking about code.
 
I couldn't get the pivots to work from an automated point of view. But I believe - with a good enough programmer and perfect forex data - they would produce money on the EUR forex. I saw them bouncing on the EUR forex (not the future) too often for it to be a coincidence. But I can't even dream of programming this, because it's too complicated. You know, it's a matter of few ticks, so your data has to be perfect. If I tried doing this, it would be like performing surgery on a moving car.

The way I'd go about it is:
1) if price is somewhat oversold, and we touch a pivot point on our way down, insert a bracket order and exit half way to the next higher pivot (with a gain) or half way to next lower pivot (with a loss).
2) viceversa for a short trade.
1) On the way down:
from a higher level of price to a lower level of price.

2) difference of a few ticks, requiring surgical precision:
If you don't have the right forex data you'll come up with the wrong pivots (and top of it you're measuring pivots on forex and you're trading futures which further complicated things)

3) using a pivot line as a target level:
As I said, I (would) use it a both a loss and target level ("bracket order"), but not from a pivot line to another, only half way, which means between the two lines.

Yes, I use code to program and back-test: I don't do back-testing in a graphical way. Nor would I automate such a system in a graphical way. I am always talking about code.

OK, if we're going discuss this seriously, I have to define a few terms.

Pivot points can be resistance, when the price has turned down, the most recent highest high is the pivot point. When it turned up, the lowest low is the support pivot point.

So when you say, "touch a pivot point on the way down" you mean, going through a support pivot point as the price falls, correct? My perception of what to do with pivots is coloured by coding the pivot indicator on the attached chart - so I'm not thinking about anything but the latest pivot as it forms behind the price, and when it does, I'd enter in the direction of the market with the pivot as the stop loss, and a target set the same distance away from the price as the stop is.

PS the chart shows pivot lines which start on the bar after the actual pivot point and continue until the next pivot on the same side of the market is formed.
 

Attachments

  • $EURUSD (30 Min)  09_06_2010.jpg
    $EURUSD (30 Min) 09_06_2010.jpg
    97.3 KB · Views: 157
Yeah, that's a correct interpretation of my point, even though I'd phrase it differently, and change this:
"going through a support pivot point as the price falls"

into this:
"touching a support pivot point as the price falls"

I'd do something similar to what you say, but I'd place the stoploss much lower than the pivot point, and the takeprofit half way between the support pivot and the next (resistance) pivot.

But as I said, this cannot be programmed by me, because I am not good enough. I can't get the right data, I can't get the right formula. Here we're talking about a surgical type of trading and back-testing this without surgical precision (which I don't have) would be a waste of time. I've tried it before and with disappointing results, not because the idea doesn't work but because there's no way to verify it with my limited programming skills - and limited data, since you need top quality forex data for the EUR pivots to work - the others work less. I could show you on a chart how well they work, but I couldn't trade them discretionary because I am not patient enough to wait for the pivot point to be reached. And as I said I can neither back-test them nor (as a consequence) automate them. So for now forget pivots.

Unless of course you have a way of doing it, and in that case I want a percentage because I gave you the idea and I own the whole pivot concept - anyone making money from pivots will have to give me a percentage from now on.

Actually it was Gladiator who told me to give pivots a chance, and I did, and he was right to insist, because he made me realize they work. So you owe him a percentage as well.
 
Top