[go: up one dir, main page]

0% found this document useful (0 votes)
877 views1 page

Pullback Script - @belgo - Trader

This document defines an indicator script that plots support and resistance levels based on a user-input period. It takes the highest high and lowest low over the given period to identify resistance and support levels, which are then plotted on the chart with customizable colors. The levels are only plotted when they change from the previous value.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
877 views1 page

Pullback Script - @belgo - Trader

This document defines an indicator script that plots support and resistance levels based on a user-input period. It takes the highest high and lowest low over the given period to identify resistance and support levels, which are then plotted on the chart with customizable colors. The levels are only plotted when they change from the previous value.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

instrument {

name = 'PULLBACK SCRIPT IG: @belgo_trader',


icon = 'indicators:RSI',
overlay = True
}

boxp=input (21, "front.newind.darvasbox.length", input.integer, 5)

input_group {
"Support and resistance",
top_color = input { default = "red", type = input.color },
bottom_color = input { default = "green", type = input.color },
}

RST = boxp

RSTT = value_when(high >= highest(high, RST), high, 0)


RSTB = value_when(low <= lowest(low, RST), low, 0)
plot (RSTT, "Resistance", iff(RSTT ~= RSTT[1], na ,top_color), 4, 0, style.levels,
na_mode.restart)
plot (RSTB, "support", iff(RSTB ~= RSTB[1], na ,bottom_color), 4, 0, style.levels,
na_mode.restart)

You might also like