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

MACD Trading Script for OTC

The document defines an instrument for a trading indicator named 'FLUXO MACD' with customizable colors for upward and downward signals. It includes conditions for plotting bullish and bearish arrows based on the closing prices of the current and previous bars. The arrows are displayed above or below the bars depending on the market conditions, using specified colors for calls and puts.

Uploaded by

Daniel Arêas
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)
213 views1 page

MACD Trading Script for OTC

The document defines an instrument for a trading indicator named 'FLUXO MACD' with customizable colors for upward and downward signals. It includes conditions for plotting bullish and bearish arrows based on the closing prices of the current and previous bars. The arrows are displayed above or below the bars depending on the market conditions, using specified colors for calls and puts.

Uploaded by

Daniel Arêas
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 {overlay = true,

name = 'FLUXO MACD',


short_name = 'OTC',
icon="indicators:ADX"}

input_group { "OTC - UP COLOR", call_color = input { default="#00FFFF", type =


[Link] } }
input_group { "OTC - DOWN COLOR", put_color = input { default="#FF00FF", type =
[Link] } }

if ((close > close[1]) and (close[1] > open[2]) and (close[3] > close[2])) then

plot_shape(1,
'Bull_OTC',
shape_style.arrowup,
shape_size.big,
call_color,
shape_location.belowbar,
0,
"MACD",
call_color )
else
if ((close < close[1]) and (close[1] < open[2]) and (close[3] < close[2])) then

plot_shape(1,
'Bear_OTC',
shape_style.arrowdown,
shape_size.big,
put_color,
shape_location.abovebar,
0,
"MACD",
put_color)
end
end

You might also like