-
Notifications
You must be signed in to change notification settings - Fork 11
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
Feature: bubble entropy (description is WIP) #384
Comments
I don't see how this is possible. I think for this feature it makes sense to have the outcome space, but not the encoding. I find this more similar to the spectral entropy and the |
Many state vectors in the same embedding can map to the same integer, because the number of sorting operations required to sort them is the same, even though the vectors are different. The order of the embedding does matter here, because the input to I've implemented my suggestion in #390. This should be clear from the source code there |
Oooooooooooioh now I understand what you mean by "vector to be sorted". I thought you meant: sort the vectors wtihin the embedded set. You mean: sort the elements of each statespace point, i.e., the same as getting the OKay, all good, I'll look at the PR now. |
Closed by #390 |
The "bubble entropy" is a method that has seen quite some usage. Framed in terms of our API, the authors do two things: 1) define a new outcome space, 2) define a
ComplexityEstimator
based on that outcome space.The method works by 1) embedding the input time series with dimension
m
, 2) for every state vectorx_i
, count the number of stepsn_i
necessary to sort a state vector in ascending order using the naive bubble sort algorithm, 3) estimate a histogram from the distribution ofn_i
s, 4) plug it into the Shannon entropy formula.This is repeat for dimension
m+1
, and the bubble entropy measure is a scaled difference between the entropies computed for dimensionsm+1
andm
. Therefore, it falls in the category of "entropy-like" measures, since it does not directly quantify an entropy. However, since it is compatible with ourOutcomeSpace
API, we should implement it as such, and define aComplexityEstimator
based on that.A
BubbleSortCount{m} <: OutcomeSpace
type can be defined, wherem
is the embedding dimension. Since, there's always a minimum0
and a maximumn(n−1)/2
number of swaps require to sort a vector of lengthn
, the outcome space is finite. We can implementencode
, but notdecode
(it isn't well-defined ... I think).encode(::BubbleSortCountEncoder, x::AbstractVector)
convertsx
into an integer in the range0:n(n−1)/2
(the number of swaps required to sortx
).decode(::BubbleSortCountEncoder, i::Integer)
does... what?HOWEVER: in the public docs, we nowhere state that
decode
must be implemented. So I'm kind of in favor of just implementing it as an encoding too, but just throwing a warning fordecode
. The method will still be useful, and can not only be used with the API here, but also iimmediately be used to define new multivariate measures in CausalityTools.jl if we implementcodify(::BubbleSortCount)
.Algorithm
The text was updated successfully, but these errors were encountered: