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 median to iterable_num #46
Conversation
I added a median function to iterable_num. I also reformatted the zero argument functions to getters (which improves readability IMO). I also updated the documentation of average to reflect the actual function.
Whoops, didn't realize that the tests were based around the current, non-getter API. Will fix and re-pull... |
Median seems like a logical accompaniment to mean, and has a use-case. In a similar vein, mode might also be included. However, the mode use-case is too niche for this package, I think. Also, I noticed that the average documentation was a bit inaccurate, so I cleaned it up... |
I'm fine with adding |
@passsy median tests and null handling have been added. Waiting for review... |
Thanks for your contribution. is |
Haha, we'll see. In all seriousness, I might make a PR with some more basic stats (mode, std dev, variance?). |
I added a median function to iterable_num.
I also reformatted the zero argument functions to getters (which improves readability IMO). I also updated the documentation of average to reflect the actual function.
EDIT: probably shouldn't have changed to getters; it's pretty useless and might break code unnecessarily. Will update PR...