oldyoungguy
Member
I have the following thinkscript and I plan to use it in 1 minute charts.
def mve13 = MovAvgExponential("length" = 13);
def mve24 = MovAvgExponential("length" = 24);
plot Buy =mve13 crosses above mve24;
Buy.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
Now I want to add another condition that should come from the 5 minutes timeframe. The condition is this:
def isGreen = HeikinAshiDiff() > 0;
So the result plot statement may look like this:
plot Buy =mve13 crosses above mve24 && isGreen;
But how can I tell thinkScript to get the "isGreen" from a higher level timeframe?
def mve13 = MovAvgExponential("length" = 13);
def mve24 = MovAvgExponential("length" = 24);
plot Buy =mve13 crosses above mve24;
Buy.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
Now I want to add another condition that should come from the 5 minutes timeframe. The condition is this:
def isGreen = HeikinAshiDiff() > 0;
So the result plot statement may look like this:
plot Buy =mve13 crosses above mve24 && isGreen;
But how can I tell thinkScript to get the "isGreen" from a higher level timeframe?