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

feat: Return result for all possible combintations of columns #5

Closed
roshnet opened this issue Apr 30, 2020 · 2 comments
Closed

feat: Return result for all possible combintations of columns #5

roshnet opened this issue Apr 30, 2020 · 2 comments

Comments

@roshnet
Copy link

roshnet commented Apr 30, 2020

Feature Request 🎉

Description

To find the score, two columns (namely the params x and y in ppscore.score()) need to be supplied in call to score().
It would be nice to have a functionality where the user can get an array of results corresponding to all columns in a single line of code.

For instance, if comparisons between columns 'A', 'B', 'C', and 'D' are to be made, it should be possible to do so with a single line of code. Results could be obtained as a list of comparisons between A-B, A-C, A-D, B-C, B-D, and C-D.

Possible Solution

This can be achieved in two ways -

  1. create another function which iterates over all possible combinations and yields/returns a list
  2. add logic to existing implementation of score for the same.

Regarding test cases, it'd be easier to write a new one for a new function (as per 1), rather than modifying the existing implementation.

Remarks

@8080labs I'd like to work on it.

@roshnet roshnet changed the title feat: Return result for all possiible combintation of columns feat: Return result for all possible combintations of columns Apr 30, 2020
@mankoff
Copy link

mankoff commented Apr 30, 2020

@roshnet how is this different than the pps.matrix function shown in https://github.com/8080labs/ppscore/blob/master/README.md?
https://github.com/8080labs/ppscore/blob/master/src/ppscore/calculation.py#L297

@roshnet
Copy link
Author

roshnet commented Apr 30, 2020

Ah, I was unaware of it at the moment. Thanks @mankoff for pointing out.
I guess this issue can be closed now.

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

2 participants