islr
notes and exercises from An Introduction to Statistical Learning
10. Unsupervised Learning
Exercise 7: Comparison of correlation based distance and Euclidean distance on USArrests dataset.
For this exercise, we’ll just show the proportionality holds in general.
The authors mention (p397) that “this is an unusual use of correlation, which is normally computed between variables; here it is computed between observation profiles”. It appears the authors intended that for observations xi,xj∈Rp,
where xi=p1∑k=1pxik is the mean over the features. This can be seen the correlation of the pairs (xik,xjk), k=1,…,p, (hence the use of the word “unusual” - the feature index has become a sample index).