Hi again (, I am the PO from my own email account)
I agree that the word "basically" puts the NA issues aside. But my
point is that R subsetting behavior when there are NAs in a logical
index is quite tricky to say the less, and deserves the trouble of
pointing it out in every place it is appro
> peter dalgaard
> on Fri, 16 Nov 2018 13:39:27 +0100 writes:
> Well, "Basically, " is an excuse for not being
> accurate. Making the code more complex doesn't really help
> the explanation. It could be better to just add "(except
> for NA handling)" or so.
> -pd
Well, "Basically, " is an excuse for not being accurate. Making the code more
complex doesn't really help the explanation. It could be better to just add
"(except for NA handling)" or so.
-pd
> On 16 Nov 2018, at 11:08 , buzon informatica, ige
> wrote:
>
> The which() function help page s
The which() function help page states that, in the default case, what the
function returns is:
" Basically, the result is (1:length(x))[x]."
That would only be true if there are not any NA values in x. I think it would
be more accurate to say:
"Basically, the result is (1:length(x))[!is.na(x) &
4 matches
Mail list logo