Setting
EMA 21 = Green
EMA 9 = yellow
MacD = 5 35 5
RSI = 10
Alma 20 0.8 8

RULES

Long:

  1. EMA 9 below 21
  2. RSI above 50 from Oversold
  3. Macd Solid green
  4. SL @ ALMA
  5. Conditional buy limit order @ top wick
  6. 1:3 RR

Short:

  1. EMA 9 above 21
  2. RSI below 50 from Overbought
  3. Macd Solid red
  4. SL @ ALMA
  5. Conditional sell limit order @ bottom wick
  6. 1:3 RR
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © markaguirre26
//@version=5
indicator(title="Moving Average Exponential", shorttitle="EMA", overlay=true, timeframe="", timeframe_gaps=true)
len = input.int(9, minval=1, title="Length")
src = input(close, title="Source")
offset = input.int(title="Offset", defval=0, minval=-500, maxval=500)
out = ta.ema(src, len)
plot(out, title="EMA", color=color.yellow, offset=offset)
ma(source, length, type) =>
    switch type
        "SMA" => ta.sma(source, length)
        "EMA" => ta.ema(source, length)
        "SMMA (RMA)" => ta.rma(source, length)
        "WMA" => ta.wma(source, length)
        "VWMA" => ta.vwma(source, length)
typeMA = input.string(title = "Method", defval = "SMA", options=["SMA", "EMA", "SMMA (RMA)", "WMA", "VWMA"], group="Smoothing")
smoothingLength = input.int(title = "Length", defval = 5, minval = 1, maxval = 100, group="Smoothing")
smoothingLine = ma(out, smoothingLength, typeMA)
plot(smoothingLine, title="Smoothing Line", color=#f37f20, offset=offset, display=display.none)
len2 = input.int(21, minval=1, title="length")
src2 = input(close, title="Source")
offset2 = input.int(title="offset2", defval=0, minval=-500, maxval=500)
out2 = ta.ema(src2, len2)
plot(out2, title="EMA", color=color.green, offset=offset2)
typeMA2 = input.string(title = "Method", defval = "SMA", options=["SMA", "EMA", "SMMA (RMA)", "WMA", "VWMA"], group="Smoothing")
smoothinglength2 = input.int(title = "length", defval = 5, minval = 1, maxval = 100, group="Smoothing")
smoothingLine2 = ma(out2, smoothinglength2, typeMA2)
plot(smoothingLine2, title="Smoothing Line", color=#f37f20, offset=offset2, display=display.none)
source = close
windowsize = input(title="Window Size", defval=20)
offset3 = input.float(title="Offset", defval=0.8)
sigma = input.float(title="Sigma", defval=8)
plot(ta.alma(source, windowsize, offset3, sigma),color=color.white)