https://www.youtube.com/watch?v=lqLEx36h5IM
instrument { name = "Slow Lower", short_name = "SLWR", overlay = true, icon="indicators:MA" }
-- shared by https://www.youtube.com/@indicadoresyplantillasgratis
-- join our free channel https://www.youtube.com/@indicadoresyplantillasgratis
period = input (14, "front.period", input.integer, 1)
source = input (1, "front.ind.source", input.string_selection, inputs.titles_overlay)
input_group {
"front.ind.dpo.generalline",
color = input { default = "#FFE850", type = input.color },
width = input { default = 2, type = input.line_width}
}
local sourceSeries = inputs [source]
plot (ema (sourceSeries, period), "EMA", color, width)
instrument { name = "Slow Lower", short_name = "SLWR", overlay = true, icon="indicators:MA" }
period = input (28, "front.period", input.integer, 1)
source = input (1, "front.ind.source", input.string_selection, inputs.titles_overlay)
input_group {
"front.ind.dpo.generalline",
color = input { default = "#3AACF9", type = input.color },
width = input { default = 2, type = input.line_width}
}
local sourceSeries = inputs [source]
plot (ema (sourceSeries, period), "EMA", color, width)
instrument { name = "Slow Lower", short_name = "SLWR", overlay = true, icon="indicators:MA" }
period = input (70, "front.period", input.integer, 1)
source = input (1, "front.ind.source", input.string_selection, inputs.titles_overlay)
input_group {
"front.ind.dpo.generalline",
color = input { default = "#3AACF9", type = input.color },
width = input { default = 2, type = input.line_width}
}
local sourceSeries = inputs [source]
plot (ema (sourceSeries, period), "EMA", color, width)
instrument { name = "Slow Lower", short_name = "SLWR", overlay = true, icon="indicators:MA" }
period = input (100, "front.period", input.integer, 1)
source = input (1, "front.ind.source", input.string_selection, inputs.titles_overlay)
input_group {
"front.ind.dpo.generalline",
color = input { default = "#3AACF9", type = input.color },
width = input { default = 2, type = input.line_width}
}
local sourceSeries = inputs [source]
plot (ema (sourceSeries, period), "EMA", color, width)
instrument { name = "Slow Lower", short_name = "SLWR", overlay = true, icon="indicators:MA" }
MaFast_period = input(1,"Fast period",input.integer,1,1000,1)
MaValue = input(5,"Value", input.string_selection,inputs.titles)
MaSlow_period = input(34,"Slow period",input.integer,1,1000,1)
Signal_period = input(5,"Signal period",input.integer,1,1000,1)
input_group {
"Sell",
colorSell = input { default = "red", type = input.color },
visibleSell = input { default = true, type = input.plot_visibility }
}
local titleValue = inputs[MaValue]
-- mdia mvel linear rpida
smaFast = sma(titleValue, MaFast_period)
-- mdia mvel linear devagar
smaSlow = sma(titleValue, MaSlow_period)
-- calculo diferencial - serie
buffer1 = smaFast - smaSlow
-- clculo da mdia mvel ponderada - serie
buffer2 = wma(buffer1, Signal_period)
sellCondition = conditional(buffer1 < buffer2 and buffer1[1] > buffer2[1] and not (buffer1 > buffer2 and buffer1[1] < buffer2[1]))
sellCondition = conditional(buffer1 < buffer2 and buffer1[1] > buffer2[1] )
plot_shape(
(sellCondition),
"+1",
shape_style.square,
shape_size.large,
colorSell,
shape_location.abovebar,
-1,
"+1",
"red"
)