The script is based on a strategy developed by Odir “Didi” Aguiar called “Agulhada do Didi”.
It consists in the use of 3 moving averages:
SMA 3
SMA 8
SMA 21
Strategy:
When the averages come together, preferably they pass through a candle, there is a signal. The crossing of the short average (3) with the long average (21) provides us with a confirma-tion of the entry.
Buy:
The average of 3 periods comes out on top, 8 goes in the middle and 21 goes down.
Sell:
Average of 21 periods comes out on top, 8 in the middle and 3 down.