Skip to content
Prev 70739 / 398502 Next

A suggestion to improve ifelse behaviour with vector yes/no arguments

On Tue, 31 May 2005, Duncan Murdoch wrote:

            
<snippage>
It wouldn't help the original poster, though.  I agree that 0,0,0,4,1,2,3 
is a slightly weird result, but I can't think of any reasonable model for 
the behaviour of ifelse() that would give any other result except an error 
message. [or  0,NA,NA,4,NA,NA,NA, I suppose].

 	-thomas