Red bar ignored

mn88

New member
VIP
Hi pegasis. Welcome to useThinkscript!

I'm at work at the moment but I might be able to help you with this later tonight if someone doesnt do it before me.

If you search youtube for "Jared Wesley" and / or "3 bar play" you will see another similar pattern. I was thinking about trying to do an indicator for so maybe I can do both at once :)
 

pegasis

New member
VIP
Here is my code from creating a scan using pattern creator for red bar ignored.

let me know what you think:

Code:
def IsUp = close > open;
def IsDown = close < open;
def IsDoji = IsDoji();
def avgRange = 0.05 * Average(high - low, 20);
plot PatternPlot =
    IsUp[2] and
    IsDown[1] and
    IsUp[0] and
    close[2] == open[1] and
    high[2] == high[1] and
    low[2] < low[0] and
    close[1] == open[0] and
    high[1] < close[0];

PatternPlot.SetPaintingStrategy(PaintingStrategy.BOOLEAN_POINTS);
PatternPlot.SetDefaultColor(GetColor(0));

I am not sure how def avgRange, and the Pattern plot is adding value?
 

Similar threads

Top