t: Friday, September 09, 2011 1:41 AM
> To: Marc Schwartz
> Cc: r-help; Alexander Engelhardt
> Subject: Re: [R] The elegant way to test if a number is a whole number
... [ many lines elided ] ...
> >>>>> is.whole <- function(x)
> >>>>> is.numeri
> Marc Schwartz
> on Thu, 8 Sep 2011 15:41:26 -0500 writes:
> On Sep 8, 2011, at 3:09 PM, David Winsemius wrote:
>>
>> On Sep 8, 2011, at 3:54 PM, Marc Schwartz wrote:
>>
>>>
>>> On Sep 8, 2011, at 2:42 PM, David Winsemius wrote:
>>>
On Sep 8, 2011, at 4:41 PM, Marc Schwartz wrote:
On Sep 8, 2011, at 3:09 PM, David Winsemius wrote:
On Sep 8, 2011, at 3:54 PM, Marc Schwartz wrote:
On Sep 8, 2011, at 2:42 PM, David Winsemius wrote:
On Sep 8, 2011, at 3:35 PM, Alexander Engelhardt wrote:
Am 08.09.2011 20:48, schrie
On Sep 8, 2011, at 3:09 PM, David Winsemius wrote:
>
> On Sep 8, 2011, at 3:54 PM, Marc Schwartz wrote:
>
>>
>> On Sep 8, 2011, at 2:42 PM, David Winsemius wrote:
>>
>>>
>>> On Sep 8, 2011, at 3:35 PM, Alexander Engelhardt wrote:
>>>
Am 08.09.2011 20:48, schrieb Marc Schwartz:
> Th
On Sep 8, 2011, at 3:54 PM, Marc Schwartz wrote:
On Sep 8, 2011, at 2:42 PM, David Winsemius wrote:
On Sep 8, 2011, at 3:35 PM, Alexander Engelhardt wrote:
Am 08.09.2011 20:48, schrieb Marc Schwartz:
There was a post from Martin Maechler some years ago and I had to
search a bit to find
On Sep 8, 2011, at 2:42 PM, David Winsemius wrote:
>
> On Sep 8, 2011, at 3:35 PM, Alexander Engelhardt wrote:
>
>> Am 08.09.2011 20:48, schrieb Marc Schwartz:
>> > There was a post from Martin Maechler some years ago and I had to search a
>> > bit to find it. For these sorts of issues, I typi
On Sep 8, 2011, at 3:35 PM, Alexander Engelhardt wrote:
Am 08.09.2011 20:48, schrieb Marc Schwartz:
> There was a post from Martin Maechler some years ago and I had to
search a bit to find it. For these sorts of issues, I typically
trust his judgement.
>
> The post is here:
>
>https://
Am 08.09.2011 20:48, schrieb Marc Schwartz:
> There was a post from Martin Maechler some years ago and I had to
search a bit to find it. For these sorts of issues, I typically trust
his judgement.
>
> The post is here:
>
>https://stat.ethz.ch/pipermail/r-help/2003-April/032471.html
>
> His
There was a post from Martin Maechler some years ago and I had to search a bit
to find it. For these sorts of issues, I typically trust his judgement.
The post is here:
https://stat.ethz.ch/pipermail/r-help/2003-April/032471.html
His solution also handles complex numbers.
HTH,
Marc Schwartz
Have a close look at ?storage.mode and ?typeof.
The problem here, as usual and as you seem to allude is: define
"integer" . Mathematically, there is an unequivocal definition, but
not so in finite precision arithmetic. Are you referring to the
machine representation (typeof()), or the approximate
Hello Alex,
Have you tried the modulus operator?
> 2 %% 1
[1] 0
> 2.1 %% 1
[1] 0.1
~Jason
On 2011.09.08 20:27:14, Alexander Engelhardt wrote:
> Hi,
>
> x <- 0.2*5
> is.integer(x)
>
> gives me FALSE because R stores it as a float number, right?
> Is there an elegant way to work aroun
11 matches
Mail list logo