-
Notifications
You must be signed in to change notification settings - Fork 153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a package to perform Mann-Whitney U test #2501
Conversation
The following ISSUES will be created once got merged. If you want me to skip creating the issue, you can use Details1. Add a Support method for finite support distributions? OrThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.2. Plot method to return a pre-configured Plot object withThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.3. For discrete distributions, use the step size toThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.4. Check these against some other implementation.This was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.5. Actually, it's at most ⌈n*m/2⌉, butThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.6. ~40% of this function's time is spent in mapassign onThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.7. The worst case for this function is when there areThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.8. The n1 and twoU values in the ukeys follow strictThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.9. Is it possible to generate this table bottom-up? IfThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.10. Later computations depend on these, but these don'tThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.11. Use symmetry to minimize UThis was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.12. Minimize U?This was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne.13. More precise bounds when there are ties.This was created by todo plugin since "TODO:" was found in 66a90c1 when #2501 was merged. cc: @nakabonne. |
/todo skip |
The following files are not gofmt-ed. By commenting pkg/app/piped/executor/analysis/mannwhitney/udist.go--- pkg/app/piped/executor/analysis/mannwhitney/udist.go.orig
+++ pkg/app/piped/executor/analysis/mannwhitney/udist.go
@@ -228,7 +228,7 @@
// bounds. It might be worth turning these into directly
// indexible slices.
A := make([]map[ukey]float64, K+1)
- A[K] = map[ukey]float64{ukey{n1: n1, twoU: twoU}: 0}
+ A[K] = map[ukey]float64{{n1: n1, twoU: twoU}: 0}
// Compute memo table (k, n1, twoU) triples from high K values
// to low K values. This drives the recurrence relation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think putting all of |
@nghialv There is no our own code in the |
I got it. I was thinking that |
Ah, sorry for confusing you. I just wanted to emphasize that is the main file where is the only file including a public function. |
Thank you! |
Way to go |
/changelog |
@nghialv: Changelog has been generated in response to this comment. |
What this PR does / why we need it:
This PR adds the
mannwhitney
package that provides a public function to perform the Mann-Whitney U test to be used by the analysis executor.NOTE: All files within the PR are just borrowed from golang.org/x/perf/internal/stats which cannot be imported from external packages, so well tested.
Which issue(s) this PR fixes:
Fixes #
Does this PR introduce a user-facing change?: