-
-
Notifications
You must be signed in to change notification settings - Fork 17
Closed
Description
Currently, if x contains 0s, these are marked as NAs.
However, there might be situations where this is unwanted (see easystats/effectsize#502).
We can add a zeros= argument, that can take the values:
"na"- the current method."signrank"- keep them during the ranking and mark them as 0.
if (zeros == "na") {
out <- rep(NA, length(x))
ZEROES <- x == 0
out[!ZEROES] <- sign(x[!ZEROES]) * rank(abs(x[!ZEROES]),
ties.method = method,
na.last = "keep")
} else if (zeros == "signrank") {
out <- sign(x) * rank(abs(x), ties.method = method, na.last = "keep")
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels