I don't understand why the value doesn't change when a new daily candle arises.
I could find a solution as follows:
//+------------------------------------------------------------------+ //+ PIVOT POINTS + //+------------------------------------------------------------------+ //Este cálculo se hace en base al método de puntos de pivote Fibonacci. double PP() {double pp = NormalizeDouble((High[1]+Low[1]+Close[1])/3,5); return(pp);} double R1() {double r1 = NormalizeDouble(PP() + ((High[1]-Low[1])*0.382),5); return(r1);} double S1() {double s1 = NormalizeDouble(PP() - ((High[1]-Low[1])*0.382),5); return(s1);} double R2() {double r2 = NormalizeDouble(PP() + ((High[1]-Low[1])*0.618),5); return(r2);} double S2() {double s2 = NormalizeDouble(PP() - ((High[1]-Low[1])*0.618),5); return(s2);} double R3() {double r3 = NormalizeDouble(PP() + (High[1]-Low[1]),5); return(r3);} double S3() {double s3 = NormalizeDouble(PP() - (High[1]-Low[1]),5); return(s3);}
However, I think something much more elegant and simple could be done, what do you think?
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Hi everyone!
I am trying to get my EA to make decisions regarding the Pivot Points, I have declared them in the header and I placed a comment to see the result, however it only calculates me with respect to the candle before the one it starts, if a new candle is opened it does not recalculate.
Can you help me to know what I am doing wrong please?