Here are the thinkscript codes for thinkorswim...just copy and paste them into new scripts. You can make one new study and put all three in there and just add the one study to the chart and it will label the wrb's...and wrbhg up or down.
WRB
def body = AbsValue(open-close); def larger = if body > body[1] and body > body[2] and body > body[3] then 1 else 0; plot wrb = if body > body[1] and body > body[2] and body > body[3] then 1 else 0; wrb.SetPaintingStrategy (PaintingStrategy.BOOLEAN_POINTS); wrb.SetdefaultColor(Color.WHITE); wrb.SetLineWeight(2); alert(larger, "Wide Range Body", alert.bar, sound.ding);
WRBHG Down
def body = AbsValue(open-close); def larger = if low[1] > high[-1] and body > body[1] and body > body[2] and body > body[3] then 1 else 0; plot wrbhg = if low[1] > high[-1] and body > body[1] and body > body[2] and body > body[3] then 1 else 0; wrbhg.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_DOWN); wrbhg.SetdefaultColor(Color.RED); wrbhg.SetLineWeight(3); alert(larger, "Wide Range Body Hidden Gap", alert.bar, sound.ding);
WRBHG Up
def body = AbsValue(open-close); def larger = if high[1] < low[-1] and body > body[1] and body > body[2] and body > body[3] then 1 else 0; plot wrbhg = if high[1] < low[-1] and body > body[1] and body > body[2] and body > body[3] then 1 else 0; wrbhg.SetPaintingStrategy (PaintingStrategy.BOOLEAN_ARROW_UP); wrbhg.SetdefaultColor(Color.RED); wrbhg.SetLineWeight(3); alert(larger, "Wide Range Body Hidden Gap", alert.bar, sound.ding);
Ryan
|