OPEN-SOURCE SCRIPT

First Candle Direction

We determine the color of the first candle based on whether the closing price is greater than or equal to the opening price.
If the closing price is higher, the candle is green; otherwise, it’s red.
sentiment

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer