Futures_Beginner
Member
Hello Geeks,
is it possible
1) To color previous 2 along with current candle based on a condition? (below example)
2) draw a rectangle to highlight these 3 candles when this condition is met
3) Comment on the chart (above high of the candle) as Candlestick pattern(Evening Star) in this case
# define candle color
def gc = close > open;
def rc = close < open;
# define conditions
def eveningstarcond1 = gc[2] && rc[1] && rc;
def eveningstarcond2 = high[1] > high[2] and low[1] > low[2];
def eveningstar = eveningstarcond1 && eveningstarcond2;
AssignPriceColor(if eveningstar then Color.MAGENTA else Color.CURRENT);
is it possible
1) To color previous 2 along with current candle based on a condition? (below example)
2) draw a rectangle to highlight these 3 candles when this condition is met
3) Comment on the chart (above high of the candle) as Candlestick pattern(Evening Star) in this case
# define candle color
def gc = close > open;
def rc = close < open;
# define conditions
def eveningstarcond1 = gc[2] && rc[1] && rc;
def eveningstarcond2 = high[1] > high[2] and low[1] > low[2];
def eveningstar = eveningstarcond1 && eveningstarcond2;
AssignPriceColor(if eveningstar then Color.MAGENTA else Color.CURRENT);