Existing indicator to show multiple of previous bar

Is there an indicator, for a candlestick chart, that can change the bar color if it’s a certain multiple size of the previous bar? For example, if a bar is 4 times or larger than the previous bar, it could change color?