Closed erblast closed 11 months ago
ks.test(rnorm(3, 10, 0.1), rnorm(3, 20, 0.1))
#>
#> Exact two-sample Kolmogorov-Smirnov test
#>
#> data: rnorm(3, 10, 0.1) and rnorm(3, 20, 0.1)
#> D = 1, p-value = 0.1
#> alternative hypothesis: two-sided
Created on 2023-10-26 with reprex v2.0.2
I cam across this issue when simulating outliers
my best guess is that the p-value gets to low to fit into Rs float vector
D == 1 means that the two samples are not overlapping. This does not automatically mean that there are low p-values if sample sizes are not so big (see example above).
so we could add a check that adds a low p-value maybe 10-6, when D == 1 and is.na(p-value)
Created on 2023-10-26 with reprex v2.0.2
Created on 2023-10-26 with reprex v2.0.2