Deadline June

Hmmm, not come across that one yet, although daresay I might. But I only intend to check rates every two hours or so.. I hope it's not an issue.
 
I didn't want to waffle on after being identified as sesquipedalian - but since I'm making you worried about the wrong thing, I'd better explain more - IB's live feed is fine, there is no problem with that. The data throttling is applied to historical data requests. IB provides up to a year or more of past data but if you request more than IB thinks is justified, it will chuck you out for 5 mins. I guess it keeps the burden on their servers down.
 
A thousandth post

Since I'm now legendary, I thought I'd post some stuff that can demonstrate just how much I've developed in those thousand posts. I guess it might look a lot like my first :jester:

I've been reading Chande: Beyond Technical Analysis thanks to MeanReversion's reference. Good book. Really oriented towards LTTF and daily data, but there's nothing he's talked about so far that I don't think I could apply to intraday data.

One thing he says is that systems developers should be aiming for systems that net $200 per trade. That is just not going to happen on intraday data for systems that catch the lower time frame trends.

I look at $/trade as the most important performance stat, which I get the feeling a lot of other traders don't, so I figure I should be able to translate Chande's $200 for daily systems into the hourly, 30mins & 15mins time frame.

If you look at the currencies, the average daily range is roughly $1000, so $200 represents 1/5 of a bar. So should I be looking at trying to make 1/5 of a bar on average for my $/trade on the 30mins time frame?

The ATR for GBP/USD is 0.0030 or 30 ticks, $300 at my leverage.

1/5 of that means I should be aiming for $60 per trade, or 6 ticks.

That would certainly cover commission and slippage and then some.

At 5 mins, the ATR is currently 0.0012 - $120 - so a fifth will be $24

That is marginal - if I can only reasonably expect a system to produce $24 per trade after working hard to put together a decent system, then it's not worth it because I could be paying that much in transaction costs.

Edit: Reading further in Chande, he regularly applies $100 transaction costs :argh: but I assume the $200 per trade figure he first quoted is without the transaction costs.
 
Last edited:
Whipsawed

:eek:

Had a lovely introduction to running live systems with the EUR/USD today.

The usually reliable system on the EUR/USD ran into turbulence overnight and only slightly redeemed itself just now.

I don't think you have to be TA wizard to guess what the signal is - actually now I'm looking at it, I can't work out why the system took the second trade....:?:

So that sequence of whipsaws cost me over a grand - fortunately the system was much better on the GBP/USDs and EUR/GBP so I'm still up for the week. Still time for a couple of trades from the system though.
 

Attachments

  • $EURUSD (30 Min)  23_07_2010.jpg
    $EURUSD (30 Min) 23_07_2010.jpg
    93.3 KB · Views: 177
Congratulations on (presumably) your first week of automated trading. Welcome to the club.
 
Man, I am feeling like ****, instead, about my systems. I have been going through a month-long drawdown, and right now I feel that my systems are ****, and I wonder if this drawdown will ever end. Nothing bad really happened, as they didn't lose anything this week, but they lost 2000 about 3 weeks ago, and now nothing good happens and it feels really really bad and boring.
 
Last edited:
Nothing bad really happened, as they didn't lose anything this week, but they lost 2000 about 3 weeks ago, and now nothing good happens and it feels really really bad and boring.

After I've got everything up and running next week I plan to spend major time doing Monte Carlo simulations on the system trades PnL, to get a big distribution curve of all the potential max drawdowns with this history.

I think the crap times are probably a lot easier to take when you can put them in perspective. If you can see that this drawdown is exactly 'here' on the distribution curve, then you know how much worse it could be, and how likely it is to improve.

Does that help?
 
Yeah, it helps. That's why I am waiting without doing anything stupid. But it's still very boring and frustrating.
 
Travis/Adamus, how do you plan to run your systems if you're away on holiday? Will you leave them running at home and periodically check (via remote access maybe?) or simply switch them off?

I tried out teamviewer.com last week and it's an easy and free way of remote accessing your machine... but you do need to have the application on the machine which is doing the accessing, i.e. it might be difficult attempting this from an internet cafe.
 
The problem at the moment that I have with remote management is that NinjaTrader is only supported with IB's TWS interface which does a forced shutdown every night. Apparently there's an app that can re-log on for you but I haven't got it, but I might try it out. Don't' have any holiday planned until Xmas so I've got time.

re remote access, I figured I might eventually rent a hosted Windows machine on the net somewhere near Greenwich Connecticut where the IB servers are. Then I could control it from any internet cafe, depending on availability of the remote access software.
 
Travis/Adamus, how do you plan to run your systems if you're away on holiday? Will you leave them running at home and periodically check (via remote access maybe?) or simply switch them off?

I tried out teamviewer.com last week and it's an easy and free way of remote accessing your machine... but you do need to have the application on the machine which is doing the accessing, i.e. it might be difficult attempting this from an internet cafe.

The problem at the moment that I have with remote management is that NinjaTrader is only supported with IB's TWS interface which does a forced shutdown every night. Apparently there's an app that can re-log on for you but I haven't got it, but I might try it out. Don't' have any holiday planned until Xmas so I've got time.

re remote access, I figured I might eventually rent a hosted Windows machine on the net somewhere near Greenwich Connecticut where the IB servers are. Then I could control it from any internet cafe, depending on availability of the remote access software.

Regarding Adamus' problem of keeping TWS from turning itself off, this is the best program of the many available:
http://twsstart.free.fr/

I don't use it because I need to turn my excel workbook on every day, and in general I would advise against letting your systems run a whole week unattended, because TWS can have bugs occasionally, which only get solved by rebooting it. Let's say something goes wrong on a Monday (usually problems happen on Mondays), if you let it run all week unattended, you lose a whole week of data/trading.

Regarding holidays, but also during the whole year, like Adamus says, I would advise running the systems from a server in the US, as he says, as near as possible to IB's servers. But the problem here is finding someone you trust, since he will have full access to your systems. I am renting a server for 250 dollars a month, near Chicago and only because I have a friend there who happens to be an ISP - not because of the CME.

However, if you don't need the data, and don't need to be running your systems all the time like I do, then it's best (for the above-mentioned problem) to run them from home, and turn them off when you go on holidays.

Whatever you do, keep both VNC and Teamviewer on, because sometimes one of them fails (rarely), and you would be screwed in that case. In case you are at a cafe, just put in your email Teamviewer and the VNC client, so you can just log into your email, start the program and connect. Of course, the people at the internet cafe might have keyloggers and log all your passwords and login details, but that's a general problem with internet cafes.

To avoid internet cafes (also because sometimes you can't find one), I would suggest getting a laptop and one of those mobile data cards, that allow you to connect from anywhere the selected carrier offers coverage. I've done it a few months ago. It worked perfectly but there was yet another type of problem: since I was very close to Corsica, on some days I got charged for roaming, despite being in Italy. After calling and complaining they still made me pay half of the roaming costs.
 
Last edited:
Of course, the people at the internet cafe might have keyloggers and log all your passwords and login details, but that's a general problem with internet cafes.

Surely there's some kind of program out there which you can download and run on an internet cafe workstation which will tell you whether it's clean or not? I haven't heard of one, but then I'd never thought that the internet cafes might be running key loggers.
 
I don't know about such program, but it should exist. Pretty hard to find though. Hopefully those running the internet cafe will be either too honest, too incompetent or too busy to run a keylogger (and check it day after day). Yet, it's also a tool they might use to protect themselves from people doing unauthorized stuff. That way they keep track of what you do, and make sure no one screws up their computers. However, if they want, they definitely are able to know anything you are typing. It might even be legal for them to run a keylogger.
 
Actually there must be remote GUI shells you can run which don't require a password, just a key, like ssh but I don't know if ssh has a windows GUI environment. I only know about its unix command-line interface.
 
Optimising optimisation

I wish I didn't have to optimise anything, but I'm using MAs and it doesn't make sense not to find the optimal parameter values for USD-CAD, EUR-JPY or GBP-USD.

Now I've accepted that I have to optimise, the next logical step is to take a system that isn't quite profitable enough to trade, and to optimise it regularly, e.g. once a year or once a month. Even better, I could do walk-forward tests to verify that it works out of sample.

One of the functions that NinjaTrader can do is walk-forward testing. You get to configure the normal optimisation range for the parameter, and then you can choose the number of days for the optimisation period, and the number of days for the walk-forward period.

When you hit Go, it will do walk-forwards period by period over the whole of the dataset and then collate the results into one at the end.

But the temptation is to over-use it by testing all different time periods for the optimsation and walk-forward periods - to the point where you are fitting parameters to your out-of-sample data despite it being out-of-sample.

I could easily run a walk-forward test over my whole data history 100 times, 1000 times and find the optimal parameters that apparently walk-forward, e.g. an MA of 13, an optimisation window of 27 days and a walk-forward period of 5 days - but haven't I actually just found what happens to work with this dataset, and curve-fitted it?
 
The things you could do are many, and in many things you could also get lost. However, whatever you come up with, if you use the OUT sample method, or even just paper trade the system for a few months after creating it, that method will never fail to tell you if your system was good.

However there is one exception. Let's say you create 100 systems, and they're all over-optimized. Then you test them in the OUT sample or even in the forward-tests (paper trade them is what i mean). In that case you will always find that some of the systems work even in the OUT sample (or the other method). Yet that doesn't mean that they are actually good, because obviously out of so many systems, some will turn out to get lucky in the OUT sample even if they are bad. Or maybe they were good but the markets just changed.

So it is quite complex I guess. Because this could actually happen even with just one system. So nothing is a guarantee of anything, unlike what I was saying at the start of this post.

But a quick and good way to discard over-optimization is to try your systems both on IN and OUT samples, on a variety of markets, and also in forward-testing (I mean paper trading it). If it passes all these tests, you will be pretty sure that - at least in the current markets (I don't know in 2000 years), the system will work.

Personally I have spent a few months exploring the way of the walk-forward optimization and I think it is a waste of time, but maybe you'll be able to get something good out of it. The way I see it now is that the system has to work forever and even if through the use of self-adaptive formulas (such as "don't trade if the range is high" or "set the take profit at half of today's range"), it should not have to be periodically optimized. Walk-forward optimization causes too many unknown and uncontrollable implications, and things have to be kept as simple as possible, so i would discard it.

I have seen many engineers, physicists, programmers who were talking to me about neural networks, high-frequency trading, a lot of stuff, start on a very long journey and never get anything done. Each time I meet them, years later, they tell me about their great and complex trading ideas, but never get anything done. What did I get done on the other hand? No money, true. But at least, within a few years of talking about this stuff, I was trading my systems. And through reckless money management these systems have doubled my capital each month for several months, then I lost everything as well, blowing out my account countless times... yes, true. But I made things happen. These neural network talking scientists are always talking and never getting even one system done instead. I see the same potential for bull**** talk regarding walk-forward optimization. I see it as something that will just make you waste a couple of years at best, if not stop and kill your trading altogether. I see it as what John Lennon calls "other plans" in "life is what happens to you while you're busy making other plans". Life is what happens to you while you're busy walk-forward optimizing your systems.
 
Last edited:
Good post, and I agree with most of it except for the fact that walk-forward optimisation in NinjaTrader takes so little time. Just set the optimisation parameters and click the button. So even if it is a waste of time, it wasn't really significant.

But at the end of the day it would take more time continually re-optimising systems.

Otherwise all the systems that I come up with which make money in the long term just trade so infrequently - on a 30 mins timeframe, I can only find systems that trade twice a month. I guess I'm being too greedy, discarding it and trying to find something that trades more. If I take these low frequency systems, I'll end up like you with 100 systems running!

In NinjaTrader, that wouldn't be difficult to set up but I think it might be a bit of a nightmare sorting out any problems if NinjaTrader has a bug in it with their automated trading and they're bound to, because it relies on the connection with IB and that's not exactly prime problem-free software.
 
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.

Trust me - i wasted my first few years of back-testing trying to create a system that took care of everything and that rarely failed, and each time I wasted my time. The more complex the system, the more it's likely to not be a healthy one. At least with my small experience, and my limited programming skills. With the little programming I know, I have to keep things simple - but that may also be a blessing. Because as i said, the most advanced people are the ones who get the least done. Whenever I read posts on elitetrader.com, in the automated trading section, I looked with more interest at the posts by people who couldn't write a proper sentence and made many spelling mistakes. Those are the ones who are probably making money. The others are too busy lecturing. They have so much knowledge that they get lost into it and lose focus on making money. Their purpose becomes knowledge rather than making money. Anyway, I was too ignorant to get the complex stuff to work, so maybe this is wishful thinking and I just want to make myself feel better.

From:
http://en.wikipedia.org/wiki/Wishful_thinking
Prominent examples of wishful thinking include:

Economist Irving Fisher said that "stock prices have reached what looks like a permanently high plateau" a few weeks before the Stock Market Crash of 1929, which was followed by the Great Depression.

From:
http://en.wikipedia.org/wiki/Irving_Fisher#Stock_market_crash_of_1929
The stock market crash of 1929 and the subsequent Great Depression cost Fisher much of his personal wealth and academic reputation. He famously predicted, a few days before the crash, "Stock prices have reached what looks like a permanently high plateau." Irving Fisher stated on October 21 that the market was "only shaking out of the lunatic fringe" and went on to explain why he felt the prices still had not caught up with their real value and should go much higher. On Wednesday, October 23, he announced in a banker’s meeting “security values in most instances were not inflated.” For months after the Crash, he continued to assure investors that a recovery was just around the corner.

So maybe I am like Fisher and 1929, or maybe I am ignorant enough to not fall in love with my own theories and deny the truth. Anyway, my theory is that, in the creation of trading systems, as in every other field, you can only understand and verify so much information. So it would be best to take one simple idea and method and test it extensively, rather than test superficially a whole bunch of complex ideas.

I could understand from the start that neural networks were out of my reach, so I discarded them, knowing i would get lost in that subject. However, i did waste a few years trying to create systems with 10 to 20 different parameters. Usually they would be as long as 40 lines of easylanguage. Today all my 60 systems are between 2 and 4 lines of easylanguage. And, instead of using 10 to 20 parameters, they use on average 3 parameters.

Here's some parameters:
1) time of the day
2) day of the week
3) month of the year
4) where price is relative to its moving average
5) where price is relative to one hour ago
6) where price is relative to yesterday's close
7) where price is relative to one week ago
8) where yesterday's close is relative to the day before yesterday's close
9) range of the day

Mix these ingredients together, even randomly, and you'll be able to produce about 10 different systems (I didn't even go that far). Then multiply these 10 different strategies by 20 different futures and you'll come up with about 200 systems, while at the same time you will verify if the strategies were good because they should work across many securities. The hardest part of the work for me is automating them. I have more ideas that work than systems because I didn't have enough time and energy to automate them.

I am not a cook, but we could compare creating systems with creating recipes. It would be pretty easy to start with a set of 20 ingredients, and create many recipes that will most likely taste (and test) good. But you first have to find and buy the ingredients (data) and you have to actually physically prepare the recipe (test, automate, paper-trade it) and then see if people like it. The creation part, when you're thinking "banana with strawberry and whipped cream will taste good together" takes a fraction of the time needed to buy it, prepare it and eat it. I think it's comparable to creating a system. Now, when I am in the bath tub like Archimedes, I almost try to keep myself from coming up with new ideas, because I know how much work it will take me to implement them, and I am still busy implementing previous ideas.

In other words, when creating systems, it is harder to implement ideas and multiply them by the many securities you can apply them to, and finding the capital needed to trade them, than the mere coming up with those ideas. Still, after all this work, even if that's only 10% of the work, I wouldn't just publish my code on a forum, out of respect for my work. But I could almost do it.

You see, many of the ideas are known to everyone: opening gap, volatility breakouts, oversold conditions... everyone knows about them. And they work. They are recipes that make money. All known edges still work and if you build a system on them, it will make money. And if you find out that it doesn't work, you can simply reverse it. There will always be an edge in the markets, since they are not random and they are not a flat line.
 
Last edited:
You're telling me to take a different path from the one which I'm so desperate to find the end of. I can see the value in everything you write, but at this point I'm not in the right place to exploit it. Perhaps I will shortly.

Hilarious quote re wishful thinking. The funniest stuff is often the stuff that you recognise in yourself.
 
Top