phidistance | R Documentation |
The pairwise phi-distance of two vectors x and y is sqrt(sum(((x[i]-y[i])^2)/((x[i]+y[i])*(sum(x)+sum(y))))). The function calculates this for all pairs of rows of a matrix or data frame X.
phidistance(X)
X |
an n times p numeric matrix or data frame |
a symmetric n times n matrix of pairwise phi distance (between rows of X) with 0 in the main diagonal. Is an object of class distance and matrix.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.