Re: [R] julian() and numerical noise

2012-03-24 Thread Andreas Eckner
quot;%Y.%m.%d") } Hope that helps, Michael On Sat, Mar 24, 2012 at 10:47 AM, Andreas Eckner wrote: Thanks for the help. A workaround seems indeed easy to write, for example, by rounding the the value of 'm' inside chron:::julian.default(), or only passing integers to the function.

Re: [R] julian() and numerical noise

2012-03-24 Thread Andreas Eckner
round is not hard to provide Michael On Fri, Mar 23, 2012 at 4:17 PM, Andreas Eckner wrote: Sorry, forgot to mention: R version 2.14.2 The function julian() is part of the "chron" package of the base distribution. On 3/23/2012 2:47 PM, Uwe Ligges wrote: On 23.03.2012 15:45, Andreas

Re: [R] julian() and numerical noise

2012-03-23 Thread Andreas Eckner
Sorry, forgot to mention: R version 2.14.2 The function julian() is part of the "chron" package of the base distribution. On 3/23/2012 2:47 PM, Uwe Ligges wrote: On 23.03.2012 15:45, Andreas Eckner wrote: Hi, does anybody know if the following behavior of julian() is intentional?

[R] julian() and numerical noise

2012-03-23 Thread Andreas Eckner
Hi, does anybody know if the following behavior of julian() is intentional? > julian(2, 1, 2012) - julian(2 - 1e-15, 1, 2012) [1] 1 > julian(2, 1, 2012) - julian(2, 1 - 1e-15, 2012) [1] 0 > julian(2, 1, 2012) - julian(2, 1, 2012 - 1e-15) [1] 0 In other words, julian() is subject to numeri