Build Neural Network Indicator in MT4 using Neuroshell

Long time a go I've read that article ...that is why I choose NSTrader..

But to prove that it will generate a profitable trade is not easy...need a lot effort
 
Long time a go I've read that article ...that is why I choose NSTrader..

But to prove that it will generate a profitable trade is not easy...need a lot effort

and expense

the programme is about $1,500 then you have the broker etc.

You might be able to offer a service arryex, of offering to babysit an average Joe through the complicated maze to a profit ??
 
Great Post! Thanks for All.

I have one question about neural network!

I use moving average crossover strategy
and I trying to build a neural network
for my strategy by using Encog Framework Java.

Please,
What are inputs and outputs
for Neural Network for my strategy (moving average crossover)?

Thank you ... Waiting for your help.
 
Hi GolderLight,

There are several methods that you may consider:
- Create a prediction to the future moving average/MA (example 5 bar or 10 bars in advance)
- Since the moving average will follow the price movement, then the price range will influence your prediction. If you train your net for price range 0-100, your MA will be within this value as well, hence in case the price range change become 0- 200, your prediction will become bad.
- It might be better if you can convert your MA into %change, Change or Momentum of moving average as your output prediction. Then you convert back predicted values into predicted MA.
- As your input you can select previous value of MA ( %change, Change or Momentum) or other oscillating indicators such as RSI stochastic, etc. I prefer to use these oscillator since they range are fix between certain range in all market condition.
- After you get your predicted MA then you can place your cross over of predicted MA as your trading strategy input.

Hope it will help you...
 
Hello guys,

I formulated a successfull strategy for gbpusd through neuroshell trader. My inputs were a mix of raw and normalised data .. i trained gbpusd from 1.55-1.70 range for 1 years and since 2009 the strategy almost generates 10-15% a year after spreads.. the only problem is that somehow when gbpusd approaches below 1.55 the strategy keeps buying thinking its good probablity to buy and end up making large losses ..

secondly as adaptive the net is of neuroshell sometimes it can be problamatic..in the last move up my net learned to buy on dips gbpusd but the recent sell off in gbpusd affected the performance because it still kept buying eeeks

is there anything you guys can suggest.. grand master arry?
 

Attachments

  • cable.jpg
    cable.jpg
    101 KB · Views: 395
Hi Supremegizmo,

To evaluate in depth about your problem, I should verify what are inputs and out that you are using (please PM me, if necessary).

In brief, probably your net producing buy at the low value and sell in the high value. Your net is trained only within 1.55 - 1.7 range hence will giving false signal is the price outside this price.
This inline with my previous statement.

To avoid your loss when the actual market outside your training boundary, my suggestion is you need to prevent trading signal if the price outside boundary. Create a new trading strategy based on previous net and avoid trading if the value is outside boundary.

Example, your new trading strategy (without optimization): Buy when tradingstrategy1 = 1 and Close > 1.55; Sell when tradingstrategy1 = 0 and Close < 1.7.

Another way is you should normalize data not tight within your range. In neuroshell2, we have option to normalize data either using [-1,1] or <<-1,1>>, if using <<-1,1>> mean the range data can go beyond -1 or above 1.

Probably others have more idea.
 
For anyone who may interested on Kohonen SOM (unsupervised classification)

Happy investing
 

Attachments

  • CLASSIFY STOCK USING KOHONEN SOM-arryex.pdf
    975.5 KB · Views: 2,766
I have fun to use my MT4 for my stock ....it works fine
 

Attachments

  • USING MT4 TO DISPLAY OWN STOCK.pdf
    651.1 KB · Views: 3,878
Hi Arryex,

I am newbie in Neural Network system and started to learn how to use it. Do you have any data pre-processing tool to be fed into NN? As we know, garbage in garbage out. How do we know that our data is good enough for NN training? I am trying to make XAU/USD trading system using intermarket analysis. Thanks.

Regard,

Lukas W

For anyone who may interested on Kohonen SOM (unsupervised classification)

Happy investing
 
Hi Lukas,

Most of data pre-processing involves translating (convert symbol to number) and normalization. Example if you have two or more categories of your input such True or false, high or low, bullish or bearish, they will be converted into number example 0 and 1, or 0 for cold, 1 for warm and 2 for hot. Normalization is converting your data into a range, example 0 to 1 or -1 to 1, etc.

It will depend on the software that you use, some of them has automatic data pre-processing (such as neuroshell2, neuroshell trader, trading solution, etc), some of them has manual step to make data normalization (neurosolutions for excel).

On certain case, you can do it using excel, as long as you know what is the formula. See attached sample.

Selecting the best input will depend on the type of NN you have, is it prediction or classification? Kohonen SOM doesn't care about the input, but if you use back propagation to predict future values then the best inputs are input which can resulting a good prediction. R square criterion, MSE, correlation, % same sign are commonly used.

Salam buat orang Indonesia...(if you are currious please PM me:D)

Happy Trading

Hi Arryex,

I am newbie in Neural Network system and started to learn how to use it. Do you have any data pre-processing tool to be fed into NN? As we know, garbage in garbage out. How do we know that our data is good enough for NN training? I am trying to make XAU/USD trading system using intermarket analysis. Thanks.

Regard,

Lukas W
 

Attachments

  • normalization sample.xls
    19 KB · Views: 306
Arryex,

Thanks for the reply. I just sent PM to you.

Regard,

Lukas W

Hi Lukas,

Most of data pre-processing involves translating (convert symbol to number) and normalization. Example if you have two or more categories of your input such True or false, high or low, bullish or bearish, they will be converted into number example 0 and 1, or 0 for cold, 1 for warm and 2 for hot. Normalization is converting your data into a range, example 0 to 1 or -1 to 1, etc.

It will depend on the software that you use, some of them has automatic data pre-processing (such as neuroshell2, neuroshell trader, trading solution, etc), some of them has manual step to make data normalization (neurosolutions for excel).

On certain case, you can do it using excel, as long as you know what is the formula. See attached sample.

Selecting the best input will depend on the type of NN you have, is it prediction or classification? Kohonen SOM doesn't care about the input, but if you use back propagation to predict future values then the best inputs are input which can resulting a good prediction. R square criterion, MSE, correlation, % same sign are commonly used.

Salam buat orang Indonesia...(if you are currious please PM me:D)

Happy Trading
 
Hi All,

This article shows how Kohonen SOM implementation using Viscovery SOMine.

My conclusion is this SOM classification help me out to select some good stocks and then use technical analysis as my trade entry/exit.
 

Attachments

  • Classify stock using Viscovery SOMine.pdf
    2.4 MB · Views: 1,557
Hi All,

Arryex, thank you for your contribution into this thread, it's very interesting :)
I try to understand self organizing maps (i.e. kohonen nn) but I need some help and I hope you could help me.
First, I'll try to explain what's the problem.

I know that SOM is a type of unsupervised learning nn and it's very good for pattern classifiaction.
I've read some books but couldn't find answer to my question.

Let's say that you have 10 patterns (X1, ..., X10) and each pattern is described by 6 features.
Now, we have to set SOM parameters(dimension) i.e. number of neurons e.g. 5x5 which is 25 neurons in total.
Next step is to train nn and suppose we're using some c++ library (e.g Kohonen Neural Network Library.).

Now, the question is, how to get/interpret output results?

If I send 1 of my 10 patterns to SOM (which is already trained) I would get 25 different numbers (each neuron gives one output). So, how could I classify my pattern?

In your paper (CLASSIFY STOCK USING KOHONEN SOM-arryex.pdf ) you had only 3 output neurons and classification was based on the minimum output (why minimum?).
 
Hi Maariuszn,

This what I found in Neuroshell2:
Kohonen networks work by clustering patterns based upon their distance from each other. There are 2 options for training criteria:

1. Vanilla or Euclidean distance metric is recommended for most networks because it works the best. If you use Vanilla, the output of the network is the square of the distance between the pattern and the weight vector for that neuron, therefore the winner is the neuron with the minimum activation.

2. Normalized takes arrays which are linear multiples of one another into the same normalized array (e.g., [1,2,6] and [2,4,12] will both be normalized to [.156, .312, .937]). You should only use the normalized distance metric when the values for all of the inputs in a pattern are in the same range. This method must be used with care and is not usually the preferred method.

If you have chosen Vanilla Kohonen (Euclidean distance metric), then the winning neurons have the smallest values. If you have chosen Normalized, then winning neurons have the largest values.

Now, please check which training criteria that you are using on your c++ library.

For a supervised classification, using PNN or back propagation, through predicted output neurons for each class, I select the minimum one as the winner neuron.
 
arryex, thank you for your answer.
could you tell me which is better for data preprocessing - normalization or standarization?
 
Hi Arryex,

Do you have any experience with NeuroSolutions? It looks as it has more features and more advanced than Neuroshell.I am going to try CANFIS network I wonder if that network available in free demo version?
 
To Maariuszn,
I do not check the benefit one of them, you can use both normalization and standardization choose which one give better result.

To Tovim,
Neurosolutions give me a good impression for many options on NN configuration, but after testing for me not giving a better result. Concerning CANFIS, Neurosolutions suggested only use maximum 5 inputs then I am stuck with my 17 inputs, I use version 5 not sure in version 6.

The error message "Due to exponential relationship between the number of input columns and the number of input processing elements, it is recommended that this model be limited to data sets that have 5 or less inputs", if I still continue with my 14 inputs the builder is not responding.
Probably Neurosolutions good for students...
 
Interesting comment from Peltarion Team '' SOMs and SVMs only work on static algorithms'' so what types of NN and SVM algos work for continous time series?
 
Top