hyppo icon indicating copy to clipboard operation
hyppo copied to clipboard

incorporate block permutation into K-sample tests

Open sampan501 opened this issue 4 years ago • 35 comments

Is your feature request related to a problem? Please describe.

Describe the solution you'd like

Describe alternatives you've considered

Additional context (e.g. screenshots)

sampan501 avatar Jan 12 '21 01:01 sampan501

Basically, like in this test, but for all the tests in the independence and k-sample module

sampan501 avatar Mar 16 '21 17:03 sampan501

@sampan501 Can I do this one?

ghost avatar Dec 17 '21 17:12 ghost

Basically, like in this test, but for all the tests in the independence and k-sample module

@sampan501 What should be done here? The description is a little bit vague. I checked the module still not sure about the required modifications.

ghost avatar Dec 19 '21 06:12 ghost

So, Dcorr supports block permutation using the perm_blocks parameter. I want that same functional, but for K-sample Dcorr. So basically add perm_blocks like auto here: https://github.com/neurodata/hyppo/blob/135cfcd6b13a986b09ec7629931bce8676ea5547/hyppo/ksample/ksamp.py#L299

sampan501 avatar Dec 20 '21 15:12 sampan501

@sampan501 You mean this part: https://github.com/neurodata/hyppo/blob/135cfcd6b13a986b09ec7629931bce8676ea5547/hyppo/independence/dcorr.py#L222-L258

for all the tests in the independence and k-sample module?

ghost avatar Dec 20 '21 17:12 ghost

That and https://github.com/neurodata/hyppo/blob/135cfcd6b13a986b09ec7629931bce8676ea5547/hyppo/independence/dcorr.py#L253 this for k-sample tests https://github.com/neurodata/hyppo/blob/135cfcd6b13a986b09ec7629931bce8676ea5547/hyppo/independence/base.py#L138 and modify this unit test to test your changes https://github.com/neurodata/hyppo/blob/5e0fe5e4337d5997f2fb1b313cd8e94540aa8807/hyppo/tools/tests/test_common.py#L265

sampan501 avatar Dec 20 '21 18:12 sampan501

That and

https://github.com/neurodata/hyppo/blob/135cfcd6b13a986b09ec7629931bce8676ea5547/hyppo/independence/dcorr.py#L253

this for k-sample tests https://github.com/neurodata/hyppo/blob/135cfcd6b13a986b09ec7629931bce8676ea5547/hyppo/independence/base.py#L138

and modify this unit test to test your changes https://github.com/neurodata/hyppo/blob/5e0fe5e4337d5997f2fb1b313cd8e94540aa8807/hyppo/tools/tests/test_common.py#L265

I don't have extensive knowledge about unit testing. I need a little bit more instruction on these. or maybe a link to learn more about these? @sampan501

ghost avatar Dec 21 '21 19:12 ghost

https://docs.pytest.org/en/6.2.x/ https://docs.pytest.org/en/6.2.x/parametrize.html#pytest-mark-parametrize-parametrizing-test-functions

sampan501 avatar Dec 22 '21 14:12 sampan501

Can you assign me this issue please? And where do I call the test_permtest function?

c-adittya avatar Apr 20 '22 15:04 c-adittya

The test_permtest function is called by pytest. I think the above links explain how the process works. Let me know if you have any questions

sampan501 avatar Apr 20 '22 15:04 sampan501