On Jun 20, 2012, at 5:18 PM, Anthony Damico wrote:
Thanks Michael,
I was hoping to complete this in one step (since I use these a lot).
Setting the class of the vectors seems like more typing than just
doing %>F% ...
Unfortunately, my knowledge of classes, methods, and the like is
pretty sha
On 12-06-20 4:44 PM, Anthony Damico wrote:
Hi, I work with data sets with lots of missing values. We often need
to conduct logical tests on numeric vectors containing missing values.
I've searched around for material and conversations on this topic,
but I'm having a hard time finding anything.
Hello, again.
I have two apologies, to the list for having forgotten to cc my previous
reply to this thread, and to you for not having understood that you
wanted it solved in one step. My solution would need two steps.
Now revised.
no.na <- function(x, value=FALSE){x[is.na(x)] <- value; x}
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On
> Behalf
> Of Anthony Damico
> Sent: Wednesday, June 20, 2012 2:19 PM
> To: R. Michael Weylandt
> Cc: r-help@r-project.org
> Subject: Re: [R] binary operators th
On Wed, Jun 20, 2012 at 4:18 PM, Anthony Damico wrote:
> Thanks Michael,
>
> I was hoping to complete this in one step (since I use these a lot).
> Setting the class of the vectors seems like more typing than just
> doing %>F% ...
Hmmm. my way save you 3 characters (and three shifts!) per
co
Thanks Michael,
I was hoping to complete this in one step (since I use these a lot).
Setting the class of the vectors seems like more typing than just
doing %>F% ...
Unfortunately, my knowledge of classes, methods, and the like is
pretty shaky. Is it possible to *create* another set of operator
Hi Anthony,
No, I don't believe this exists on CRAN already (happy to be proven
wrong though) but I might suggest you approach things a different way:
instead of defining this operator by operator with infix notation, why
not go after `+`, `>` directly? If you put a class on your vectors,
you can
gt; Subject: [R] binary operators that never return missing values
>
> Hi, I work with data sets with lots of missing values. We often need
> to conduct logical tests on numeric vectors containing missing values.
> I've searched around for material and conversations on this to
Hi, I work with data sets with lots of missing values. We often need
to conduct logical tests on numeric vectors containing missing values.
I've searched around for material and conversations on this topic,
but I'm having a hard time finding anything. Has anyone written a
package that deals with
9 matches
Mail list logo