Between Moving Averages
For example
Bullish pattern when Price is over EMA 21 and 55
Bearish pattern = when Price is under EMA 55 and 21
I've tried but I see errors in TOS
tried this formula:
and saw error: Exactly one plot expected
please help!
For example
Bullish pattern when Price is over EMA 21 and 55
Bearish pattern = when Price is under EMA 55 and 21
I've tried but I see errors in TOS
tried this formula:
Code:
input fastMALength = 21;
input slowMALength = 55;
input averageTypeFast = AverageType.Exponential;
input averageTypeSlow = AverageType.Exponential;
plot fastMA = MovingAverage(averageTypeFast, close, fastMALength);
plot slowMA = MovingAverage(averageTypeSlow, close, slowMALength);
AssignBackgroundColor(if close > fastMA then Color.DARK_GREEN else if close < slowMA then Color.DARK_RED else Color.Dark_ORANGE);
and saw error: Exactly one plot expected
please help!
Last edited by a moderator: