Hi BF1,
Most charting software will allow you to do this. You can do it for free in
StockCharts You can also create ratio charts which show (in your example) whether IBM is outperforming or underperforming the index. You can also create correlation charts which, as the name implies, tells you the degree to which the two are correlated.
Enjoy!
Tim.