Professional Documents
Culture Documents
Close: "Utt Bars) " "Barcolor I / 0 ? " "ON" "OFF" "OFF"
Close: "Utt Bars) " "Barcolor I / 0 ? " "ON" "OFF" "OFF"
// Definition : INDICATORS
// RSI
_rsi = rsi(close,14)
// MACD
fun_macd(_src,_fastlen,_slowlen,_signallen) =>
float _output = na
_macd = ema(_src,_fastlen) - ema(_src,_slowlen)
_signal = ema(_macd , _signallen)
_output := _macd - _signal
_hist = fun_macd(src,12,26,9)
// MOMENTUM
t_mom = 10
_output = 0.00
_length_adjusted = _length < 0 ? 0 : _length
// BOLLINGER BANDS
// CM GUPPY EMA
//Fast EMA
ema1 = ema(src, len1)
ema2 = ema(src, len2)
ema3 = ema(src, len3)
ema4 = ema(src, len4)
ema5 = ema(src, len5)
ema6 = ema(src, len6)
//Slow EMA
ema7 = ema(src, len7)
ema8 = ema(src, len8)
ema9 = ema(src, len9)
ema10 = ema(src, len10)
ema11 = ema(src, len11)
ema12 = ema(src, len12)
// DEEP LEARNING
// INPUTS :
input_1 = tangentdiff(_indicator1)
input_2 = tangentdiff(_indicator2)
input_3 = tangentdiff(_indicator3)
input_4 = tangentdiff(_indicator4)
input_5 = tangentdiff(_indicator5)
input_6 = tangentdiff(_indicator6)
input_7 = tangentdiff(_indicator7)
input_8 = tangentdiff(_indicator8)
input_9 = tangentdiff(_indicator9)
input_10 = tangentdiff(_indicator10)
input_11 = tangentdiff(_indicator11)
input_12 = tangentdiff(_indicator12)
input_13 = tangentdiff(_indicator13)
input_14 = tangentdiff(_indicator14)
input_15 = tangentdiff(_indicator15)
input_16 = tangentdiff(_indicator16)
input_17 = tangentdiff(_indicator17)
input_18 = tangentdiff(_indicator18)
input_19 = tangentdiff(_indicator19)
// LAYERS :
// Input Layers
n_0 = ActivationFunctionTanh(input_1 + 0)
n_1 = ActivationFunctionTanh(input_2 + 0)
n_2 = ActivationFunctionTanh(input_3 + 0)
n_3 = ActivationFunctionTanh(input_4 + 0)
n_4 = ActivationFunctionTanh(input_5 + 0)
n_5 = ActivationFunctionTanh(input_6 + 0)
n_6 = ActivationFunctionTanh(input_7 + 0)
n_7 = ActivationFunctionTanh(input_8 + 0)
n_8 = ActivationFunctionTanh(input_9 + 0)
n_9 = ActivationFunctionTanh(input_10 + 0)
n_10 = ActivationFunctionTanh(input_11 + 0)
n_11 = ActivationFunctionTanh(input_12 + 0)
n_12 = ActivationFunctionTanh(input_13 + 0)
n_13 = ActivationFunctionTanh(input_14 + 0)
n_14 = ActivationFunctionTanh(input_15 + 0)
n_15 = ActivationFunctionTanh(input_16 + 0)
n_16 = ActivationFunctionTanh(input_17 + 0)
n_17 = ActivationFunctionTanh(input_18 + 0)
n_18 = ActivationFunctionTanh(input_19 + 0)
// Hidden Layers - 1
n_19 = ActivationFunctionTanh( -0.000052 * n_0 + 0.000023 * n_1 + -0.000002 * n_2 + 0.000030 * n_3 + 0.000048 * n_4 + -0.000430 * n_5 +
-0.000184 * n_6 + -0.000083 * n_7 + -0.000118 * n_8 + -0.000184 * n_9 + -0.000230 * n_10 + -0.000273 * n_11 +
-0.000310 * n_12 + -0.000362 * n_13 + -0.000362 * n_14 + -0.000356 * n_15 + -0.000350 * n_16 + -0.000344 * n_17 +
-0.000335 * n_18 + -0.053564 )
n_20 = ActivationFunctionTanh( -0.000055 * n_0 + 0.000025 * n_1 + -0.000002 * n_2 + 0.000032 * n_3 + 0.000051 * n_4 + -0.000457 * n_5 +
-0.000195 * n_6 + -0.000088 * n_7 + -0.000126 * n_8 + -0.000196 * n_9 + -0.000244 * n_10 + -0.000291 * n_11 +
-0.000329 * n_12 + -0.000385 * n_13 + -0.000385 * n_14 + -0.000378 * n_15 + -0.000372 * n_16 + -0.000366 * n_17 +
-0.000357 * n_18 + 0.070562 )
// Hidden Layer 2 :
// Output Layer
_output = ActivationFunctionTanh( -0.188169 * n_21 + -0.233289 * n_22 + -0.187686 * n_23 + -0.161870 * n_24 + -0.169295 * n_25 + -0.154724 * n_26 + -0.711455 )
// MACD : SEED
fastLength = 12
slowlength = 26
signalLength = 9
// Conditions :
//Plot data
plot(hist, color=(positive_condition ? color.rgb(229, 233, 13) : color.rgb(204, 8, 243)), style=plot.style_histogram,linewidth= 5 , title="Histogram", transp=0)
// Definition : Barcolor
_lights = 0.00
if (lights=="ON")
_lights:= 1.00
if (lights=="OFF")
_lights:= -1.00
color_condition() =>
(positive_condition and _lights == 1.00) ? color.rgb(243, 239, 2) : (negative_condition and _lights == 1.00) ? color.rgb(227, 9, 235) : na
color barColor = na
barColor := color_condition()
barcolor(color = barColor)
// Alerts