Euclidean Distance between two matrices
distance2(x1, x2)
x1
Matrix 1
x2
Matrix 2
Suhai (Timothy) Liu
X<-matrix(1:12,3,4) Y<-matrix(5:16,3,4) distance2(X,Y)