How to make Indicator containing spread?

 
I have a account at a market maker. The spread sometimes widens extremely. So I like to program an indicator to show the spread.

I adopted the excellent „Clock_v1_3” indicator from „Jerome  to show the current spread besides the different time zones.

I am new to programming indicators so I do not know how to store the spread in the indicator value array. My plan is to store the maximum spread that occurred in a candle as the indicator value. I am afraid I would have to program something like “Spread Data Logger“ see https://www.mql5.com/en/code/10102 and read the logged data. Is there an easier way to get spread values for the indicator?

As I have not contacted „Jerome“ I do not know if it would be ok to post my current indicator source code that is mostly a copy of the Clock indicator.