The following code will plot the close
series data:
plot(close)
However, I want to normalize the close series by today’s close value:
// If the today's (latest) close is 165, we will divide the close series by 165.
plot(close/165)
This will give us a normalized series where the latest normalized value will be 1
, and we can compare different securities together (forward comparison).
The latest close varies every day. How could I normalize the close series by today’s close value?
The following code is not correct:
// close[0] mean the close data on the drawing bar, not today's close (latest close)
plot(close/close[0])