Zigzag Value (( Last-Current)*38%)
-
I need to make a condition that:
1)- Close of candle (0) is greater than (((Zigzag (1) - Zigzag (0)) * 38%) + Zigzag (0))
2)- Buy -
I'm not sure how to get zigzag (1) as I never use the indicator, but here's the math part at least:
https://fxdreema.com/shared/4VeDgy30d -
But here i dont think maths are right. Here is what you are doing :

If you want to buy on a upward fibonacci retracement, the condition is always gona be true as : Z1-Z0 is negative, subtracting this difference this difference from Z0 actual which is the same value as the actual candle, the result is always gona be below the actual candle.