[R] 1-Pearson's R Distance
cbeleites at units.it
Thu Nov 27 17:00:58 CET 2008
afaik, (1 - r_Pearson)/2 is used rather than 1 - r_Pearson. This gives a
distance measure ranging between 0 and 1 rather than 0 and 2. But after all,
dies does not change anything substantial.
see e.g. Theodoridis & Koutroumbas: Pattern Recognition.
I didn't know of the proxy package, but the calculation it straightforward
(though a bit wasteful I suspect: first the whole matrix is produced, and
as.dist cuts it down again to a triangular matrix):
as.dist (0.5 - cor (t(x) / 2))
Take care wheter you want to use x or t(x).
Dipartimento dei Materiali e delle Risorse Naturali
Università degli Studi di Trieste
Via Alfonso Valerio 6/a
phone: +39 (0 40) 5 58-34 47
email: cbeleites at units.it
More information about the R-help