Trapping Candles
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © Jainbaba

//@version=5
indicator("Trapping Candles",overlay = true)
bool val = false
bool val2 = false
if volume[0] > volume[1] and (close < open)
    val := true
plotshape(val,style=shape.xcross,color=color.green)
//if volume[0] > volume[1] and (close > open)
//    val2 := true
//plotshape(val2,style=shape.xcross,color=color.red,location=location.belowbar)

