'
This commit is contained in:
parent
cc9704489c
commit
5fdff9fee2
2 changed files with 6 additions and 6 deletions
10
R/find.R
10
R/find.R
|
|
@ -2,9 +2,9 @@
|
|||
#' @description Emulates behavior of `find`
|
||||
#' @param x object or logic operation on an object
|
||||
find <- function(x) {
|
||||
if (is.logical(x)) {
|
||||
return(which(x))
|
||||
} else {
|
||||
return(which(x > 0))
|
||||
}
|
||||
if (is.logical(x)) {
|
||||
return(which(x))
|
||||
} else {
|
||||
return(which(x > 0))
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue