Direction
Esta função retorna a direção simplificada de uma vela, ou seja, se a vela é positiva ou negativa. (-1 = Negativa, 0 = Neutra, 1 = Positiva)
Parâmetros
| candle; | // A vela de referência. | ||
| timeframe | = CURRENT; | // O tempo gráfico de referência. | |
| symbol | = SYMBOL; | // O ativo de referência. |
Exemplos
1//Default example:
2Direction[candle, timeframe = CURRENT, symbol = SYMBOL]
3
4//Using aliases:
5DIR[candle, timeframe = CURRENT, symbol = SYMBOL]
6
7//Other examples
8Direction[1]
9Direction[1, M5, "EURUSD"]
10DIR[1] == 1 // Check if the candle is positive/buying