-
Notifications
You must be signed in to change notification settings - Fork 14
Complexity measure API, v2 #133
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
Comments
How does having a |
With a multiscale(e::Entropy, alg::MultiScaleAlgorithm, x::AbstractVector, est::ProbabilitiesEstimator; kwargs...)
multiscale(c::ComplexityMeasure, alg::MultiScaleAlgorithm, x; kwargs...) Without it, the exported functions would be multiscale(e::Entropy, alg::MultiScaleAlgorithm, x::AbstractVector, est::ProbabilitiesEstimator; kwargs...)
multiscale_sampleentropy(alg::MultiScaleAlgorithm, x; kwargs...)
multiscale_approx_entropy(alg::MultiScaleAlgorithm, x; kwargs...)
multiscale_reverse_dispersion(alg::MultiScaleAlgorithm, x; kwargs...)
multiscale_statistical_complexity(alg::MultiScaleAlgorithm, x; kwargs...)
multiscale_missing_disp_patterns(alg::MultiScaleAlgorithm, x; kwargs...)
... |
Moreover, there are multiple variations on, for example, multiscale sample entropy. With this approach, we can capture all variations of it using parameters of |
Okay I agree with the proposed API. I don;t agree with having both the |
Ok, good!
I get the point. However, the issues previously raised about search engine visibility etc still apply. We've been insisting on keeping convenience methods for e.g.
If argue that if we want to use the visibility argument for the case of specific entropies (probabilities), we should also apply it for the case of complexity measures. If not, we should just drop the convenience methods completely. |
I don't get your point. Search engines work with keywords. In the docstring of whatever method you will have the keywords "Approximate entropy". Search engines won't find function names, because they don't have spaces and hence don't qualify the keywords the engines search for. We definitely have the keywords "permutation entropy" in the library.
From my perspective the reason to keep a few of these convenience methods is (1) for education purposes so that users learn that the permutation entropy is just a subclass of something more general and (2) for the future paper, so that we can highlight that, if we were using the approach of alternative software, we would offer 1000s upon 1000s of functions, but instead we manage the same amount of content with much less function definitions. |
Excellent point. Shall we keep the current entropy convenience methods, and perhaps add one or two convenience methods (for the sake of educational purposes) complexity measures too? With only two functions ( A simple (nonexhaustive) table in the documentation could replace many of the convenience methods, and can be a good way of ensuring all common names appear somewhere in the documentation. This may also serve as a starting point for a table listing common literature methods for our paper, e.g.
We'll reach similar numbers of possible combinations for the complexity measures in the future, too, I guess. A similar table could be useful.
|
I like this a lot! The table is great! Only change I would do is replace Okay let's keep the |
Great! @ikottlarz this will affect your PR #131. Do the designs of I'll submit a PR within the hours where I re-do the reverse dispersion method with the new API, so you can see how it'll look in the end. |
@kahaaga this sounds good to me. I'm currently working on your reviews, and will reorganize my code accordingly! |
Closed by #134 |
The need for a common
complexity interface
This issue supersedes #81.
I think we should have a common interface for computing various entropy-like complexity measures, such as
reverse_dispersion
(already implemented),sample_entropy
(#71 ),approximate_entropy
(#72),missing_dispersion_patterns
(#124),statistical_complexity
(#131), etc (currently open PRs).It is fine to have the methods
sample_entropy
,reverse_dispersion
,statistical_complexity
, but I really, really like the genericentropy
interface where we just dispatch on differentEntropy
methods andProbabilitiesEstimators
, and would like something similar for other complexity measures.Deciding on an interface like this is important because:
complexity
interface would hugely simply the implementation of multiscale methods (Multiscale analysis #132).Suggested interface
I propose the following:
Every complexity measure can then just have its own complexity type that we can dispatch on, e.g.
What do you think, @ikottlarz and @Datseris ?
The text was updated successfully, but these errors were encountered: