Technical Analysis – Any use after all?
[Originally published June 2007. Obviously, ha ha, oil’s been a LOT more interesting since then. However, the same principles continue to apply.]
So how good is my trader-fu?
In Mar 2006, I showed a couple of charts and explained a little about Technical Analysis (TA).
At the time, the charts looked like this, and I predicted (and I quote):
“Oil has been dropping, a little, but it looks like it’s about to explode in one direction, and probably upwards“
I got to wondering about this the other day – was I right? Well, here’s what the charts look like now:
note that the previous charted ended at the start of the coloured rectangle
I’ve put the same indicators on there as last time. To re-summarise:
Top chart, red wiggly lines: Bollinger Bands – when they cramp together, the market is humming and harring to itself – they expand out when it takes off (in either direction)
Bottom chart, histogram+lines at bottom: MACD – magenta is general trend (below zero=down, above=up), yellow shows change in that trend, green dotted is a smoothed version of the change in trend
(that’s the Cliff notes version, anyway).
Ok, so, let’s see how we went. The left hand of the coloured rectangle is where I did the analysis – right at the end of March, 2006.
In the next month, oil went racing up to (almost) all time highs, hitting 94.60 on the 21st April. Excepting the one point where the market flicked to around 97, in Aug 2005, this is the highest the market has EVER been. So, that was a pretty good estimate – and bang on time too.
Of course, things got a LOT more interesting after that.
The next big peak
See that extra peak, just to the right, in July 2006 (rightish side of the box)? Wow, I bet a few people dropped a stack of cash on that one. That’s almost the highest oil has EVER been, 95.49 (again, only beaten by Aug 2005 – which if you remember was when hurricane Katrina took out most of the major oil refineries for the entire USA).
The really interesting thing was the day after that peak, namely 17 Jul 2006. The market high was 94.54. Hang on a minute – within 6/100 of a dollar of the peak we predicted in April? What are the odds of that? Well, that’s the thing with traders, they’re damn superstitious. So, when the high the previous day wasn’t sustained, people would be looking to see if the market stayed above the previous (April) high. It didn’t – which often bodes very, very bad things. It means that, essentially, people just don’t have that much faith in the market – not enough to put their money where their mouth is, at least.
This pattern (where the market creates a top, then goes up to it and nudges it again) is called a double top. Usually the market will drop away as much as it climbed up to the left of the first top (ie, at least down to 80, maybe 75), in about the same amount of time.
So, anyway a lot of times, you get a massive, massive drop. Maybe not overnight, but soon, real soon. People start to panic.
See how in August (two bars from right hand edge of the box), it climbed up again, but this time it couldn’t even muster the energy to nudge the previous high? Nope, people are getting nervous. Time to bring your emergency pants onto the trading floor.
End of the rectangle – how many pairs of pants will I need?
So, at the end of the rectangle is a really good time to look at the indicators again. The market has dropped, but not too far – still in the previous trading range (ie, above 85). Is it going to plummet, or still keep kicking around? What do the indicators tell us?
The bollinger bands (red, at the top) have been cramped in tight for some time, about three months. This means where-ever the market is going to go, it’s going to explode, and a LOT. See how usually they kinda pick a direction and go there, up, down, up, down, always somewhere? Well, for three months they’ve been in going horizontal. This is also called “range trading” (coz, you know, they’re trading in a range. Traders aren’t a super imaginative lot. You may have noticed).
Ok, so bollinger says something is well overdue. What does MACD tell us?
Well, here’s where you have to be careful. Pink was above, a little, but has just crossed down. Does this mean a drop? Well, maybe – but notice the same rough pattern happened in June with no major market drop. So, it could be a false alarm.
How about the yellow line? Well, this is a bit different. Remember this tells us how fast the trend is changing. Usually you can compare it to the green line for further sensitivity. See where pinko dropped in June, how ol’ yella nudged against green dotty, but didn’t cross it in any major way? Well, have a look at it now. Yellow is below green, and dropping fast, REALLY fast. You can also see that in a bar or two, the yellow line crosses the zero – further indicating how fast the market is moving. If you look at the picture, everytime this sort of thing happened, there was a massive move. The last time was in Oct 2005, and the market dropped 15 big points.
Yeah, yeah, yeah, but what does this all MEAN?
Well, first let’s talk about 15 big points. What does that mean? Well, normally when people talk “points”, at least in this market, they’re actually talking about movements of 0.01. Why? Because each 0.01 is worth $10 per contract. It’s pretty usual to trade anywhere from 5 to 50 contracts at a time. Since 3-400,000 contracts a day get traded, you know there are people in there trading very, very big numbers. A thousand contracts, several thousand, big money.
So, each point move of 0.01 is worth $10. Which means that a full decimal point, a big point (ie, 100 ‘points’ = 1 ‘big point’) is worth $1000 per contract.
Now think back to Oct 2005. That means if you held just a single contract, you would have made, or lost (if you were long) $15,000, in two months. That’s US Dollars.
Now have another look at the drop that started in July last year. It went from 95 down to a low of around 60 in Jan 2007. That’s 35 big points. $35,000 a contract. Even if you got in at the right hand side of the rectangle, in August, when the market was around 86, if you’d held waiting for a definite cross in the MACD, which happened in about Feb (at 66), that would be $20,000 in profit. Per contract.
And even that little move I predicted last year? From around 84->94? That’s a cool $10k per contract, my friends – just for paying a little attention on livejournal. Who ever thought this place would pay off in numbers like that?
So you wanna trade futures, eh kid?
Of course, before you rush off and get a futures account, have another look at the MACD, and the Bollinger Bands. These are just two indicators. TA has thousands of the damn things. They jump around like madmen and give crazy signals left right and centre. This is not a game for people with weak stomachs. 90% of people trading lose money (the other 10% do very, very well, of course). Personally, I’ve watched $50k of my own money disappear in about half an hour. This is not a story that raises any eyebrows when I tell other traders – it’s pretty typical. It’s also pretty typical that any trader will biff away USD200k or more in “education” before they start to play a steady game. It’s definitely not for everyone. It’s not even for well adjusted people, it could quite reasonably be argued.
I heard a story, years ago, that if you wanted to be a futures trader, you need to do the following: Wait for a really windy day. Gale force was best. Go down to the bank, and pull out $10,000 in high denomination notes. Walk to the centre of the town square, and throw the whole lot in the air. Watch it all blow off down the street, then go home and sleep well, really well that night. Think to yourself “Ok, that was stupid. I won’t do that again”, and nothing more. If you can do that? Then this might be the game for you.
I used to think it was just a nutty story. Then I traded a whole bunch. Now I think the number is probably a bit low. Try at least $20k, that’s what I’d recommend.
If, however, you think you can handle that kind of pain, and sleep well the following night, then hey, come on in! The water’s lovely!
related
Technical Analysis + Multi Objective Optimisation = Happy Si
[originally published Mar 2006]
The first thing: a link. Namely, the wiki page on the category of Technical Analysis (some back story on what the hell TA is, is here).
Short(ish) version, for the lazy (or, you know, those of you at work): TA is a way of turning largely incomprehensible charts, like this:
into much more informative charts, like this:
or this:
Ok, I can hear you screaming already. What the hell IS all this stuff?
The first chart. That’s light crude. Aka, oil. When people talk about the price of oil? That’s what they’re talking about [ed: uhh, to be anal, they’re generally talking about WTI – West Texas Intermediate, but this is generally number 2]. That’s a weekly chart, of the last two years. So you can see why petrol’s so damn expensive these days. Just so you know.
The second chart is called Bollinger Bands. John Bollinger was just a dude. A smart dude, but we don’t have to talk about him to get the gist of this.
Basically, Bollinger Bands tell us how much the market movement is contracting, or expanding. See how the lines kinda get closer, and then suddenly, bang! the market takes off? Yeah. That’s what Bollinger Bands are really handy for.
So, we can look at the chart and say useful things. Interesting things. Like “Hmm, light crude is going to consolidate (ie, not jump around as much) a little more, then we’re going to get a strong directional move“.
This doesn’t tell you if it’s going up or down (we’ll get to that), but it’s still handy to know. It means “keep your emergency pants ready”
The third chart is MACD. This stands for Moving Average Convergence Divergence. *yawn* yeah, exactly.
It’s a bit complicated, but here’s the basic gist: it gets a bunch of moving averages together, and measures how much they changing relative to each other.
Moving Average? Just think “average”. It’s the same thing.
wt F ? Why the hell would we bother to do this? Who cares, I mean, really?
Stay with me here, I’ll explain, then you’ll go “ohhhh!”
Some of the lines are “faster” (ie, they react quicker to changes in the data). The difference bit is where we start subtracting, say, a fast average from a slow one. What does this give us? Ahh, see, that tells us how fast the market is changing. Ie, not direction (up or down) so much, although it does tell us that too, but how quickly it’s changing direction.
So, it gives us advance warning about when the market is changing direction. Sure, you get bad warnings from time to time. These are called (amongst other things) false breakouts, or false signals. These are a big problem. We’ll get back to that later. Of course, you know, if predicting the market was easy, we’d all be billionaires. Ho Ho.
Ok, so let’s explain MACD.
At the top, to help explain, I’ve put two moving averages, a red slow one (changes slowly), and a white fast one (changes quickly).
The MACD is at the bottom and it works like this:
The yellow line is the difference between the white and red one. See how the yellow one goes down when the white and red get closer together? Yep, that’s why.
The blue line (bit hard to see) is a smoothed out version of the yellow one.
The magenta bars are the difference (stay with me here) between the yellow and blue (so when the blue and yellow cross each other, see how the magenta also crosses the zero line? Yep, that’s it).
In other words. You can look at the squiggly lines at the bottom and see direction, and changes in direction, and also how much and fast the market is moving in that direction (by how high the magenta bars are).
Oooh, that’s gotta be useful, right? right? right?
Of course, you might be saying, I can look at the chart and see that anyway. Key thing is this – you can’t see the future, so, having these lines helps clarify what might be happening soon.
So, in short, let’s say things are going up. Ok, blah blah, buy buy, etc. Wouldn’t it be useful to know when things were going to start going down, so you could, I dunno, sell, before you lost all your money? Well, MACD helps with that. Because before things start going down, they have to stop going up. Yep. a big duh right there, but it’s important. MACD helps us to see when things are slowing, and where they might be going next. Yes, false breakouts happen a lot. We’ll get to that.
So now, ooh! Useful information. We can look at the third chart and say things like (put your best boffin voice on), “Hmm, light crude is currently trending downwards, very slightly, but it’s slowing and about to change” (see the yellow line tilting up? yep, that’s how. magenta is below zero, ie, downtrend. yellow is turning up, ie, the market is maybe starting to turn).
We wouldn’t say definitively that it’s in an uptrend until the yellow line at least crosses the blue (ie, the magenta bars will be above zero), because, har har, we have to draw the line somewhere.
So. With technical analysis, we can say a much more useful thing like “Oil has been dropping, a little, but it looks like it’s about to explode in one direction, and probably upwards“.
Which, since we know that petrol prices at the pump tend to follow light crude a little slower (oil companies are big, and slow), we can say “Expect prices to go up markedly in a couple of month or so“.
See? Wasn’t that helpful? Wasn’t that fun?
So, technical analysis is pretty cool.
Even cooler than TA is the bunch of algorithms that make it up, because then you can do all sorts of interesting measurements. The above is really just a taste.
Oooh, I like algorithms. Algorithms are my happy friend.
Ok, second thing:
ooh! I can see you’re excited already.
Ok, maybe not.
So what’s so cool about this? Ahh! I’m glad you asked.
MOO. That’s what. Multi objective optimisation (last item on the contents)
STOP YAWNING!
Let me explain. When you’re trying to solve a problem. A real problem. An interesting problem, you typically have to try and satisfy more than one criteria at once.
For example. Let’s say you want to go out with the best boy in school. What do you do?
You don’t just want someone cute. You also want someone tall. With pretty eyes. And smarts. And a good kisser. And well dressed. And so on.
Each of these is an “objective“. Goal, criteria, call it what you like.
Either way, you want to try and get as many of these as possible.
Now, if you just wanted the tallest boy, that’s easy. Line them up, walk to the end of the line. Voila.
Ditto if you just want the cutest boy. Or the boy with the prettiest eyes.
Thing is though, you want all those things. So, you might settle for, say, the boy with the second prettiest eyes, if he was also the cutest. Or perhaps the second tallest, third cutest, fourth prettiest eyes, because he was the best option.
But really, how do you know what the best option is? You weigh all these things together, in your head, and decide.
That’s what Multi Objective Optimisation is.
Except, instead of “boys in your school”, think “boys in the known universe”, and instead of 5 criteria, think, say, 50.
Any real problem. The interesting ones, the ones worth solving, are like this.
These are the problems I work on. And yes, I love it.
So, an historical view of the entire field of MOO (queue jokes now) is gonna have a whole lot of really useful information, right?
Well, it does. So, what did I learn? I learnt:
a) that I’ve more or less worked my way through all the research in the field done during the 1980’s.
remember, I’m just sitting in a room thinking this stuff up as I go along. So really, this is pretty good going. It gets better
b) I’ve also figured out some of the more successful techniques from the 90’s and 00’s.
Which is nice
c) also, there lots and lots of nifty cool interesting and successful other techniques for me to try out
All in all, a pretty damn interesting read.
So, so, so. Why the two of these together? Well, it’s like this.
What about if you got the computer to put algorithms together, with multiple objectives?
You could say things like “make me a moving average that reacts quickly, but doesn’t give me false breakouts“
or maybe “tell me which way the trend is going, but make less mistakes than MACD does“
or perhaps “tell me when the market is slowing down and about to change direction” – which is a good time to get out of a trade. Of course, the catch is, if the market slows, but then takes off in the same direction, you’ve just left a lot of money on the table. This is what us professionals call “Bad”.
With TA + MOO, anything you can dream of, anything you can think up, you could get it to do. Or at least have a damn good crack at.
Think Transformers here. Think Optimus Prime on steroids. Think infinitely flexible, infinitely expandable, infinitely connectable.
Yeah, kick ass.
So, you can see. This is pretty damn exciting. It’s kinda magical, really. There’s the possibility to come up with some pretty darn gnarly new stuff.
This is as much fun as a handful of kittens.. dropped in the middle of a knitting basket.
This is pretty much like getting an email that starts out:
Dear Sir
You have been selected from millions of people on our lists..
to tour our Giant Fire Breathing Robot Squid Factory.
I mean really, what more could a guy like me ask for?