Need this below conditions

Can someone help with creating this scanner.

Verify this , you can change conditions according to candle colour.