FXCM Forex Trading

Perceptron – Single layer neural network

If you need an Indicator or Signal developed or translated from other language, please post all Indicator development REQUESTS to this section here.

Moderator: admin

Perceptron – Single layer neural network

Postby isamegrelo » Sun Oct 08, 2017 3:18 pm

Formula:

// --- settings ---
//weight in % for each neuron
//x1=5
//x2=10
//x3=25
//x4=50
//indicator previous period
//y1=0
//y2=7
//y3=14
//y4=21
// --- end of settings ---

//indicator to be used by the neural network
indi = average[5](rsi[14])

w1=x1-100
w2=x2-100
w3=x3-100
w4=x4-100
a1=indi[y1]
a2=indi[y2]
a3=indi[y3]
a4=indi[y4]

return(w1*a1+w2*a2+w3*a3+w4*a4)



Indicator in this chart:

Image
isamegrelo
 
Posts: 22
Joined: Mon May 29, 2017 3:36 pm

Re: Perceptron – Single layer neural network

Postby Apprentice » Mon Oct 09, 2017 4:42 am

Try this fixed version.
viewtopic.php?f=17&t=65166
This is the original version, I believe there is a bug in this indicator logic.
Perceptron2.lua
(3.43 KiB) Downloaded 16 times
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 17168
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia


Return to Indicator and Signal Requests

Who is online

Users browsing this forum: Exabot [Bot] and 5 guests