[R] Obtaining translated, rotated and scaled matrics in procrustes analysis
ali_protocol
mohammadianalimohammadian at gmail.com
Thu Apr 26 08:52:04 CEST 2012
Hi all,
I wondered how I can get the translated, rotated and scaledmatrix in a
procrustes analysis. This does not help:
##############################
library (vegan)
#defining the target matrix:
a= cbind (c (1,2,3,4), c( 10,12,14,16))
#defining the matrix to be rotated:
b= a; b[,2]= c(9,11,15,16)
c=procrustes (a,b); g=fitted (c)
# trying to get to the procrustes matrices:
d= t (apply(b,1,'-',c$translation))
#points ( d, col=4)
e= d %*% c$rotation
#points ( e, col=6)
f= e* c$scale
#points ( f, col=7)
# Should be a matrix(0,3,2) but is not:
f-g
#(!) Thanks in Advance.
--
View this message in context: http://r.789695.n4.nabble.com/Obtaining-translated-rotated-and-scaled-matrics-in-procrustes-analysis-tp4589030p4589030.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list