/----
for(i = limit; i >= 0; i--) For each Bar starting at the oldest
{
if(High > LastHigh) If the previous bar is a new high
LastHigh = High; Cache the new High
//----
if(Low < LastLow) If the previous bar is a new low
LastLow=Low;Cache the new low
if(TimeDay(Time) != TimeDay(Time))
{ If this bar is the start of a new day, print the open close and high
Print(DoubleToStr(Close, Digits));
Print(DoubleToStr(High[0], Digits));
Print(DoubleToStr(Low[0], Digits));
Basically it's collecting the highest high and the lowest low from limit bars back in time.
/----
for(i = limit; i >= 0; i--) For each Bar starting at the oldest
{
if(High > LastHigh) If the previous bar is a new high
LastHigh = High; Cache the new High
//----
if(Low < LastLow) If the previous bar is a new low
LastLow=Low;Cache the new low
if(TimeDay(Time) != TimeDay(Time))
{ If this bar is the start of a new day, print the open close and high
Print(DoubleToStr(Close, Digits));
Print(DoubleToStr(High[0], Digits));
Print(DoubleToStr(Low[0], Digits));
Basically it's collecting the highest high and the lowest low from limit bars back in time.
Tanks 4xcoder for you help,
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
HI Guys ,
I wonder if someone can please explain what does this code mean...
/----
for(i = limit; i >= 0; i--)
{
if(High > LastHigh)
LastHigh = High;
//----
if(Low < LastLow)
LastLow=Low;
if(TimeDay(Time) != TimeDay(Time))
{
Print(DoubleToStr(Close, Digits));
Print(DoubleToStr(High[0], Digits));
Print(DoubleToStr(Low[0], Digits));
Thanks