Skip to content
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

If my mock data contains weights, how can I conduct a KS test considering the weighted values? #6

Open
astro-sjgao opened this issue Jun 5, 2023 · 2 comments

Comments

@astro-sjgao
Copy link

No description provided.

@kcroker
Copy link

kcroker commented Jun 5, 2023 via email

@syrte
Copy link
Owner

syrte commented Jun 5, 2023

This is an interesting problem but beyond the scope of this code.

It is possible to compute similar statistics. You will need to modify the code yourself and incorporate the weights when computing the probability in each quadrant (in the function quadct).
This line also should be changed using the weight

D1[:, 0] -= 1 / n1

Moreover, the distribution of the KS distance might be different. Bootstrap resampling is recommended to estimate the p-value of the distance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants