Compare current candle with previous candle

onthing

New member
Would please share the code to compare last closed candle with current time frame or future candle
like comparing 30 minute candle of 9:30-10AM candle with current 10-10:30AM

Code:
def agg = AggregationPeriod.THIRTY_MIN;
def c1 = close(period = agg);
def c=close[-1];
plot data=c>c1;
 

Similar threads

Top