Open karoliskoncevicius opened 2 years ago
Currently row_wilcoxon_twosample does not produce a warning when all the values are constant and equal to the NULL:
row_wilcoxon_twosample
row_wilcoxon_twosample(c(1,1,1), c(2,2,2), exact=FALSE, null=1) # NaN p-value but no warning
In a similar situation row_wilcoxon_onesample() can end up producing three warnings for the same row:
row_wilcoxon_onesample()
row_wilcoxon_onesample(c(0,0,0)) # 3 separate warnings are produced
And the above issue is also present in a paired version.
Solution: add the warning for "twosample" case and adjust the warnings so that only one is produced at the time.
Currently
row_wilcoxon_twosample
does not produce a warning when all the values are constant and equal to the NULL:In a similar situation
row_wilcoxon_onesample()
can end up producing three warnings for the same row:And the above issue is also present in a paired version.
Solution: add the warning for "twosample" case and adjust the warnings so that only one is produced at the time.