I created a set of labels that I want to show Red when1m candle is red and green when 1min candle is green.
What I made isn't working properly so any help will be greatly appreciated. For some odd reason all of the labels turn at the same time even when one of the others is different. I am not sure if this is showing the one minute TF.
What I made isn't working properly so any help will be greatly appreciated. For some odd reason all of the labels turn at the same time even when one of the others is different. I am not sure if this is showing the one minute TF.
Code:
# Candle Color Indicator
declare upper;
# Calculate candle color
def isGreen = close > open;
def isRed = close < open;
# Plot labels
AddLabel(isGreen, "AAPL: " + close("$AAPL"), Color.GREEN);
AddLabel(isRed, "AAPL: " + close("$AAPL"), Color.RED);
AddLabel(isGreen, "QQQ: " + close, Color.GREEN);
AddLabel(isRed, "QQQ: " + close, Color.RED);
AddLabel(isGreen, "$ADD: " + close("$ADD"), Color.GREEN);
AddLabel(isRed, "$ADD: " + close("$ADD"), Color.RED);