I've just installed R 1.7.1 under linux red hat I noticed sign reversal of eigen vectors ,some of them not all, upon using diag function relative to those obtained using R 1.4.1 this is gonna miss up lots of my previous scripts I wonder if there is a way to avoid this. best regards karim
eigen vector sign reversal
5 messages · Karim Elsawy, Roger D. Peng, Martin Maechler +2 more
I think at version 1.7.0 R started using LAPACK for its eigen/svd routines. I think using `eigen(x, EISPACK = TRUE)' uses the previous version. -roger
Karim Elsawy wrote:
I've just installed R 1.7.1 under linux red hat I noticed sign reversal of eigen vectors ,some of them not all, upon using diag function relative to those obtained using R 1.4.1 this is gonna miss up lots of my previous scripts I wonder if there is a way to avoid this. best regards karim
______________________________________________ R-help at stat.math.ethz.ch mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help
"Roger" == Roger D Peng <rpeng at stat.ucla.edu>
on Tue, 15 Jul 2003 10:19:38 -0700 writes:
Roger> I think at version 1.7.0 R started using LAPACK for
Roger> its eigen/svd routines. I think using `eigen(x,
Roger> EISPACK = TRUE)' uses the previous version.
Yes (2 x).
But it the eigen vectors *are* determined only upto
multiplication with +/- 1.
So I think Karim should consider improving the R scripts that
have been dependent on particular signs of the eigen vectors.
Roger> Karim Elsawy wrote:
>> I've just installed R 1.7.1 under linux red hat I noticed
>> sign reversal of eigen vectors ,some of them not all,
>> upon using diag function relative to those obtained using
>> R 1.4.1 this is gonna miss up lots of my previous scripts
>> I wonder if there is a way to avoid this. best regards
>> karim
Martin Maechler <maechler at stat.math.ethz.ch> http://stat.ethz.ch/~maechler/
Seminar fuer Statistik, ETH-Zentrum LEO C16 Leonhardstr. 27
ETH (Federal Inst. Technology) 8092 Zurich SWITZERLAND
phone: x-41-1-632-3408 fax: ...-1228 <><
On Tue, 15 Jul 2003, Roger D. Peng wrote:
I think at version 1.7.0 R started using LAPACK for its eigen/svd routines. I think using `eigen(x, EISPACK = TRUE)' uses the previous version.
Yes, but as the sign of eigenvectors is not well-defined it may be better to fix the scripts so that they don't care. -thomas Thomas Lumley Assoc. Professor, Biostatistics tlumley at u.washington.edu University of Washington, Seattle
1 day later
On Tue, 15 Jul 2003, Roger D. Peng wrote:
I think at version 1.7.0 R started using LAPACK for its eigen/svd routines. I think using `eigen(x, EISPACK = TRUE)' uses the previous version.
That is true, but using different compilers on the same machine and the same version of R may give different signs for the eigenvectors. The moral is, don't rely on the signs of eigenvectors! (This *is* on the help page.)
Karim Elsawy wrote:
I've just installed R 1.7.1 under linux red hat I noticed sign reversal of eigen vectors ,some of them not all, upon using diag function relative to those obtained using R 1.4.1 this is gonna miss up lots of my previous scripts I wonder if there is a way to avoid this.
Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595