# How to normalize stock data

Recently, I've been using such formulas:

1. Log prices = Ln(Close(t))

2. Close(t)-Mean

3. (Close(t)-Mean)/(StdDev)

4. Ln(Close(t))-Mean

Is there any other ways?

• For what reason you need do that? – Svisstack Oct 18 '13 at 12:16
• I need it to construct spreads within different instruments.To compare them on the same chart. – Vladimir Oct 18 '13 at 12:28
• Sorry but "normalizing" is not clear enough. Do you mean "scale", do you mean "I want improve stationarity on a time serie using a transformation", please be clearer about what you want – statquant Oct 18 '13 at 13:51
• statquant, you are correct, i'd like to "improve stationarity on a time serie using a transformation" – Vladimir Nov 14 '13 at 13:58
• Why are you doing what you're doing? – user2763361 Mar 7 '14 at 8:41

If you can assume one instrument to be the 'base' instrument then the ratio of the prices is a good measure with both time series beginning at the same time. This is similar to calculating relative return. I have used this when backtesting a pairs trading system.

Happy to help.

• Hi NN1983! What advantages exactly do you get for using relative returns in backtesting? – H. Arponen Oct 19 '13 at 8:35
• The entire strategy was being based on mean reversion between prices. We would trade based on whether the ratio of the two prices was mean reverting and when it would breach certain thresholds. It converted two time series to one that we could run our tests on. – NN1983 Oct 22 '13 at 7:20
• Ah OK... I guess that wouldn't work for a portfolio bigger than two assets... – H. Arponen Oct 23 '13 at 19:11
• I suggested this because I thought you said spreads between instruments which I am having trouble imagining between more than two instruments. It would definitely help if you told something about the spreads that you are planning to work on. As with what @statsquant said, you need to be clearer what you mean by 'normalizing'. – NN1983 Oct 24 '13 at 12:23

Here are some more :

1. Ln(Close) - Ln(Close1) : Close1 is previous close.
2. (Close-Close1)*100/Close1
3. (Close-LowN)/(HighN-LowN) : LowN and HighN are the low and high within the last N values.