[R] build on Irix failed reg-tests
Peter Dalgaard
p.dalgaard at biostat.ku.dk
Wed Mar 17 23:35:37 CET 2004
Prof Brian Ripley <ripley at stats.ox.ac.uk> writes:
> I think NA+0 should be special, though. All of mine give
>
> > NA+NaN
> [1] NA
> > NaN+NA
> [1] NA
>
> That's with four separate compilers on Sparc-Solaris as well as Windows
> and Linux i686.
>
> I have long wondered why it works ....
I get the same as Andy on Opteron, with another curious twist:
> NA-NaN
[1] NA
> NA+NaN
[1] NaN
> NaN+NA
[1] NA
> NaN-NA
[1] NaN
Looks like Thomas is right and we need to fix up the logic of all the
vectorized ops. Drats!
-p
> > > #ifdef IEEE_754
> > > REAL(ans)[i] = REAL(s1)[i1] + REAL(s2)[i2];
> > > #else
> > >
> > > This doesn't look as thought it is guaranteed to work, though
> > > it does on
> > > most machines. It clearly can't work where both operands are NaN, so
> > > under OS X I get
> > > > NA+NaN
> > > [1] NA
> > > > NaN+NA
> > > [1] NaN
> > >
> > >
> > > -thomas
> > >
> >
> > On our Opteron I get:
> >
> > > NA+NaN
> > [1] NaN
> > > NaN+NA
> > [1] NA
> >
> > OK, now I'm really confused...
> >
> > Andy
> >
> >
> >
> > ------------------------------------------------------------------------------
> > Notice: This e-mail message, together with any attachments,...{{dropped}}
> >
> > ______________________________________________
> > R-help at stat.math.ethz.ch mailing list
> > https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
> >
> >
>
> --
> 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
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
>
--
O__ ---- Peter Dalgaard Blegdamsvej 3
c/ /'_ --- Dept. of Biostatistics 2200 Cph. N
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
More information about the R-help
mailing list