-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Currently, 'test', 'yes' and 'no' can have inconsistent dimensions without any warning or error even with strict=TRUE
> test=rbind(alpha=c(A=TRUE, B=FALSE),beta=c(FALSE, TRUE))
> yes=matrix(nrow=1, ncol=4, 1:4)
> no=matrix(nrow=4, ncol=1, 1:4*10)
> ifelse1(test, yes, no)
A B
alpha 1 30
beta 20 4
> ifelse1(test, yes, no, strict=TRUE)
A B
alpha 1 30
beta 20 4
> yes+no
Error in yes + no : non-conformable arrays
I would expect an error (or at least a warning) by default on the ifelse1() operation.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels