From yaacov@mscc.huji.ac.il  Thu Apr 27 11:56:54 2000
From: yaacov@mscc.huji.ac.il (jr)
Date: Thu, 27 Apr 2000 13:56:54 +0300
Subject: [Rd] R
Message-ID: <005101bfb038$02ff34c0$57058b80@ritov>

I guess there is a mistake in the function princomp (package mva).
I believe that the scores are computed wrongly under cor=TRUE condition:

Lines 42-43:

    if (scores && !missing(x))
        scr <- scale(z, center = TRUE, scale = FALSE) %*% edc$vectors

should be replaced by something like

     if (scores && !missing(x) && !cor)
        scr <- scale(z, center = TRUE, scale = FALSE) %*% edc$vectors
    if (scores && !missing(x) && cor)
        scr <- scale(z) %*% edc$vectors


Sincerely

************************************************

Ya'acov Ritov
Department of Statistics
The Hebrew University of Jerusalem,
Jerusalem 91905
Israel
Tel. (972-2) 652-9929 (Okay way)
Fax (972-2) 652-9996
http://pluto.mscc.huji.ac.il/~yaacov/jr.html
AND THIS IS ANOTHER PROOF THAT IF YOU KEEP AN OPEN MIND, SOMEBODY WILL FILL IT
WITH RUBBISH (an anonymous BBC correspondent)


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


[Rd] R
jr