Neural networks

Discussions about the testing and simulation of mechanical trading systems using historical data and other methods. Trading Blox Customers should post Trading Blox specific questions in the Customer Support forum.
Post Reply
dispassionate
Full Member
Full Member
Posts: 15
Joined: Wed Jan 11, 2006 9:02 pm
Location: London

Neural networks

Post by dispassionate » Mon Nov 06, 2006 12:31 pm

What defines a neural network exactly? Is the term as used in financial markets just a load of bollocks?
Is it just a system that is complicated simply because it has a lot of rules programmed into it?

BARLI
Roundtable Knight
Roundtable Knight
Posts: 650
Joined: Sat Jan 17, 2004 6:01 pm
Location: USA

Post by BARLI » Mon Nov 06, 2006 1:45 pm

you can learn about NN
HERE

Tim Arnold
Site Admin
Site Admin
Posts: 8501
Joined: Tue Apr 06, 2004 1:41 pm
Location: Boston, MA
Contact:

Post by Tim Arnold » Mon Nov 06, 2006 4:30 pm

Although the encyclopedia definition is interesting, I think the question is quite valid as it relates to trading systems that define themselves as "Neural Networks."

I would have to agree with dispassionate that it sounds like a load of something.

BARLI
Roundtable Knight
Roundtable Knight
Posts: 650
Joined: Sat Jan 17, 2004 6:01 pm
Location: USA

Post by BARLI » Mon Nov 06, 2006 6:04 pm

the friend of mine who uses NN in his trading provided the following answer:



The basic answer to what is a neural network is that it is a "universal approximator". What this means is that with enough examples of a set of inputs, and a set of desired outputs, then a neural network can "learn" to approximate what the output should be when it sees a previously unseen set of inputs.

Simple example: We all know a formula to calculate RSI, but... a neural network can "learn" this formula (or a pretty good approximation of it) all by itself.
How? Well, lets imagine that we passed a neural network all the inputs required to calculate RSI, and for every set of inputs that we passed the network, we also told it what the actual value of RSI would be (if we actually calculated it). With enough examples, the neural network would build its own function which very closely approximated the real function for building RSI.

You are probably wondering what the use of this is, as we already have a function for calculating RSI. The point is, the neural network can take a set of inputs and build a function that will be a close approximation of a set of required outputs.

A better example:
Instead of building RSI for the next time period, which we can already do, what about building RSI for a future time period (like in 3 days time). Pass the neural network whatever the causal inputs are, and what value the RSI had 3 days after those inputs, and it will learn for itself a function which is a close approximation of RSI three days into the future.

Caution:
a neural network can curvefit. This means it will "learn" the best function that it can, even if there really isn't any relationship at all. Therefore, its down to us to ensure that we pass data as inputs that are likely to be causal. It makes sense to most of us to use RSI as a predictor, because we have probably all seen examples of it in use, and accept it is likely causal. However, as long as we can establish a causal relationship of inputs to outputs, then we're OK. There are a number of things we need to do to avoid curve fitting in neural networks, such as limiting the number of hidden neurons (which are effectively free parameters), and being cautious with settings for momentum and training rate.

Future:
The next step to getting involved with neural networks is to start thinking about what it is you actually want a neural net to do for you. The obvious step of creating a neural net, loading all the indicators you can think of as inputs, and training against 2 day returns isn't a good move forward. The neural net will undoubtedly learn something useful, but it probably won't be enough to help you profit. I would advise concentrating on training neural nets to fit into your current trading strategy. For example, if you're a long term trader, and you pyramid positions, then don't train a neural net to pick your initial entry point, as you are probably already pretty good at that, and it probably won't learn anything 'better' than a simple 30 day ema crossover (or something equivalent). Train it to pick the best exit point, or the best point to pyramid a position. Let the neural network focus on what it does best, and use it to complement the skills you already have.

nodoodahs
Roundtable Knight
Roundtable Knight
Posts: 218
Joined: Wed Aug 09, 2006 4:01 pm

Post by nodoodahs » Thu Nov 09, 2006 4:28 pm

http://www.data-mines.com/Resources/CAS ... tified.pdf

The paper was written by an actuary looking at the issue of predicting loss costs for various classes of insured, but it is an applicable description of the neural network technique. You could easily apply the concepts to fundamental, technical, or fundatechnical information about stocks or futures to data mine for situations that lead to good average results over a certain timeframe, and then develop entry and exit strategies around that data.

Personally, I think NN is mathematical masturbation, too much activity for what, in the end, is a less than fully satisfying result. Both in the insurance industry, and in trading, I think simpler solutions are the best.

BARLI
Roundtable Knight
Roundtable Knight
Posts: 650
Joined: Sat Jan 17, 2004 6:01 pm
Location: USA

Post by BARLI » Thu Nov 09, 2006 4:30 pm

nodoodahs wrote: Personally, I think NN is mathematical masturbation, too much activity for what, in the end, is a less than fully satisfying result. Both in the insurance industry, and in trading, I think simpler solutions are the best.
agree

Roscoe
Roundtable Knight
Roundtable Knight
Posts: 250
Joined: Sat Jan 24, 2004 2:06 am
Location: Houston TX

Post by Roscoe » Sat Nov 11, 2006 5:09 pm

nodoodahs wrote:Personally, I think NN is mathematical masturbation, too much activity for what, in the end, is a less than fully satisfying result. Both in the insurance industry, and in trading, I think simpler solutions are the best.
Amen! NN sounds good, at least until you think about it a bit, at which point it is just a sophisticated form of curve-fitting.

Old European
Roundtable Knight
Roundtable Knight
Posts: 144
Joined: Mon Apr 19, 2004 3:04 pm
Location: Old Europe

Post by Old European » Sun Nov 12, 2006 3:57 am

Indeed, it is curve-fitting in its most most extreme form.

ronblack
Full Member
Full Member
Posts: 11
Joined: Mon Oct 23, 2006 7:07 pm

Post by ronblack » Thu Nov 16, 2006 1:19 pm

nodoodahs wrote: Personally, I think NN is mathematical masturbation, too much activity for what, in the end, is a less than fully satisfying result. Both in the insurance industry, and in trading, I think simpler solutions are the best.
I looked at Tradecision http://www.tradecision.com but I stll don't understand what it does. Is it just a fancy way of optimizing systems? It's not very clear what these neural networks do. From what I understand they estimate probabilities of a certain strategy to work in the future. Has anyone used this program?

I think one must distinguish between data mining programs and neural networks. I'm looking right now at APS http://www.tradingpatterns.com and this is more like a data mining program.

I think the difference between these two programs is that Tradecision requires some model as input but APS does not. However, APS is limited to price patterns. I still haven't decided which one to get. Maybe try both.

Ron

[/url]

nodoodahs
Roundtable Knight
Roundtable Knight
Posts: 218
Joined: Wed Aug 09, 2006 4:01 pm

Post by nodoodahs » Thu Nov 16, 2006 1:54 pm

Read the paper referenced above for a more detailed analysis. It's not mine, but I've met the author, sweet little old bird.
http://www.data-mines.com/Resources/CAS ... tified.pdf

NNs are a tool used to data mine, one of many such tools, a sub set of the data mining world. They can be described as a generalized linear regression technique designed to be used with limited human intervention, and grew out of artificial intelligence (AI) research. As such, it is a newer, "sexy" field and attracts more attention than I think it should based on usefulness and quality.

All data mining aims at actionable responses; more traditional forms also stress the human understanding of the relationships of the variables involved, whereas NN couldn't give a crap whether humans understand the relationships ...

Old European
Roundtable Knight
Roundtable Knight
Posts: 144
Joined: Mon Apr 19, 2004 3:04 pm
Location: Old Europe

Post by Old European » Thu Nov 16, 2006 3:57 pm

Neural networks indeed grew out of Artificial Intelligence research in the 80s. It was a not entirely unsuccessful attempt to simulate the working of the human brain and in particular its self-learning capability. This technique has since also been applied to other scientific disciplines. It however never led to satisfactory results (except when trying to simulate the human brain).

But is the human brain (and the discretionary trader) good at taking trading decisions? I'm afraid that the answer is no! This means that it is thus highly unlikely that applying the self-learning neural network technique to trading will yield promising results.

Cheers,

Old European

jaym

Post by jaym » Thu Nov 16, 2006 10:27 pm

Hi,

There seems to be a great deal of judgment in this thread. Neural networks are a well researched area and have been applied successfully in an incredibly wide range of areas.

It is not the "tool" that is inappropriate but the way in which it is used and just overall when it is applied. It should be noted that these techniques (and many similar ones) have been applied successfully in financial market trading.

Powerful techniques like this should not be used unless they are fully understood as every part that is not fully understood is thus exposed to an unknown level of risk (possible error).

Another point of interest is that “curve-fittingâ€

JonS
Full Member
Full Member
Posts: 11
Joined: Mon Jul 07, 2003 1:05 am

Post by JonS » Fri Nov 17, 2006 12:24 am

Jay,

Neural networks require a considerable investment in terms of time to develop, explore, test and evaluate. In the time that I have put in, I have so far been disappointed with the results for the effort involved.

Clearly, my efforts are neither here or there, but coming from that place, what I am now consequently most sensitive to is the distinction between the theoretical statement of what a neural net can do versus the actual trading application successes out there. And in particular, how this is superior to a more traditional mechanical system. This is the evidence that I would be most interested in.

I contrast this with Gann enthusiasts. Very many of them will talk for hours on the theory in hindsight and all of its terrific features - and perhaps they are right (who knows) - but there is a deafening silence when they are challenged to publicly detail their precise trading strategy in 'advance' and have that record available for public scrutiny.

I am still fascinated by neural nets but some evidence of concrete trading success would be reassuring.

danZman
Roundtable Knight
Roundtable Knight
Posts: 117
Joined: Thu Mar 10, 2005 10:07 am
Location: Newport Beach,CA

Post by danZman » Fri Nov 17, 2006 4:03 am

Let's be frank about something...whether we use Trading Blox or Neural Networks, we're curve fitting to some degree. If I want to find the best pain/gain ratio with TB, I'm going to keep testing all parameters until I get the best. Well, this is what NNs do. Only they use some calculus to get to the answer perhaps a bit faster.

NN's are not the holy grail, but they can give you answers just the same as a brute force method (like TB). Instead of stepping the variables one by one, they take derivitives to get closer to want you might want faster. As you can probably see, FASTER is the key word. But in this age, does that really matter? Not so much if you think simple is better.

This gets me into another subject...how much of an edge can we expect in the future with simple trading systems? Eckhardt brought this up, and what he says makes me want to make as much as possible now before my edge is gone.

Maybe Richard Dennis was right about being able to publish trading rules in the newpaper and yet it would still be viable. That of course suggests the majority will ALWAYS look at fundamentals. That seems to be the case today, but I think it's getting tougher to be a trend follower. Alas, this gets me into another topic...

D

nodoodahs
Roundtable Knight
Roundtable Knight
Posts: 218
Joined: Wed Aug 09, 2006 4:01 pm

Post by nodoodahs » Fri Nov 17, 2006 7:03 am

jaym wrote:There seems to be a great deal of judgment in this thread.
You say that as if applying judgment to the choice of tools were a bad thing. I think applying judgment to the choice of tools is a good thing.
jaym wrote:If you desire to find out if something "works" commit to the full length of time required to truly research it and let the results speak for themselves.
I've been doing data analysis, one form or another, in insurance since '96. NNs are used by several companies and actively promoted by a few vendors; I have experience looking at NN pricing and underwriting models used by companies I've worked for and competed against; I've read some but not all of the literature. I stand by my opinions expressed above.

FWIW, I think most people type "curvefitting" when they mean "overfitting" which is a real danger and is discussed in the NN literature.

BARLI
Roundtable Knight
Roundtable Knight
Posts: 650
Joined: Sat Jan 17, 2004 6:01 pm
Location: USA

Post by BARLI » Fri Nov 17, 2006 7:11 am

danZman, you bring some interesting points here. Why do you think trend following became tougher? What I've noticed about my trading is that I get screwed up when I fight the trend trying to go counter cos I think it's gone way too far, of course there's a price for it to pay... Fundamentals play some role and we can't ignore it, I've had bad experience recently ignoring fundamentals of grain shortages.

RedRock, you used to be in the pit for some time, I read in New Market Wizards that lotsa guys lost money when they fought Silver trend in late 1979, no one could believe it could go higher then 15$ and Mark Ritchie said he saw people losing the fortunes that those locals made during years of trading, only because they didn't notice the change in fundamentals. If you were on the floor during some strong bull or bear market I'd like to hear some of your experiences or of those who traded side by side with you :wink:

RedRock
Roundtable Knight
Roundtable Knight
Posts: 939
Joined: Fri Jan 30, 2004 3:54 pm
Location: Chicago

Post by RedRock » Fri Nov 17, 2006 2:50 pm

BARLI wrote:
RedRock, you used to be in the pit for some time, I read in New Market Wizards that lotsa guys lost money when they fought Silver trend in late 1979, no one could believe it could go higher then 15$ and Mark Ritchie said he saw people losing the fortunes that those locals made during years of trading, only because they didn't notice the change in fundamentals. If you were on the floor during some strong bull or bear market I'd like to hear some of your experiences or of those who traded side by side with you :wink:
Most of the traders in the MMI (blue chip) in mid 80s had pretty good poker faces. All types of players from smaller locals counting waves, to the arbs trading between the other indicies and cash. One guy who is still a friend today had a strong sense of the bigger picture. He would often be the notable one in the middle of the pit buying anything on a "scarry" lower open. In that way, he gave others confidence to join in and set the trend for the day. Next thing the arbs would come in and start playing the spread thus pulling the cash up and "making things real". Those were interesting days. That little pit with a hundred or so guys could in effect 'wag the dog' to some extent on a short term period. It was easier to do than say in the sp, which took much more to push around in the first place.

Post Reply