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

Reimplement methods from kotlin-statistics #405

Open
altavir opened this issue Aug 16, 2021 · 2 comments
Open

Reimplement methods from kotlin-statistics #405

altavir opened this issue Aug 16, 2021 · 2 comments
Labels
feature A new feature request good first issue The issue awaits its hero. Contributions are welcome

Comments

@altavir
Copy link
Member

altavir commented Aug 16, 2021

Port/re-implement methods from https://github.com/thomasnield/kotlin-statistics. Use stream-based reduction and Buffer.

The API is here: https://github.com/mipt-npm/kmath/blob/dev/kmath-stat/src/commonMain/kotlin/space/kscience/kmath/stat/Statistic.kt

Example usage is here: https://github.com/mipt-npm/kmath/blob/dev/kmath-stat/src/jvmTest/kotlin/space/kscience/kmath/stat/StatisticTest.kt

One needs to implement a Statistic class/object for each quantity from kotlin-statisitcs. If the reduction could be done in parallel, one should use ComposableStatistic instead.

Use Mean and Median as a reference.

@d-lowl
Copy link

d-lowl commented Nov 27, 2021

Just fyi, I have made a start on this issue today (porting geomean first) -- https://github.com/d-lowl/kmath/tree/port-statistics
I'll see how much I can squeeze out this weekend.

@altavir
Copy link
Member Author

altavir commented Nov 28, 2021

I am very happy to hear that. Please do not hesitate to write if you think that there should be some changes in the statistic API. I made it this way so we could do non-blocking streaming processing of large data. But it is not much tested yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature A new feature request good first issue The issue awaits its hero. Contributions are welcome
Projects
None yet
Development

No branches or pull requests

2 participants