Am 28.07.2017 um 13:00 schrieb Riccardo (Jack) Lucchetti:
Two more things on this; one, I wrote
> But if you insist in doing so,
I know that princomp() should be applied to data, not to the cov-matrix.
This is just a minimal numerical example to showcase the issue (and with
some path dependence also playing a role).
the first principal component on the
> covariances can be returned ok,
Yes that's exactly what I meant and why I didn't understand that
princomp() doesn't manage to do that.
which is wrong, because you should centre the data first, and use
cdemean(A) in place of A.
OK, but AFAICS doesn't change anything of the princomp() problems here.
Two, I found that princomp actually uses standardised data when
computing its output even when the third argument is non-zero, which is
IMO wrong.
Could be. I vaguely remember some of those things were discussed when
the third optional argument was introduced (the covariance-based variant).
cheers,
sven