Double ANN: SignalDecomposition.jl + TimeseriesSurrogates.jl

Because I have been posting a lot of announcements lately, and because I don’t want people to start hating me for unending spam, I will announce two new packages in JuliaDynamics in this post: SignalDecomposition.jl and TimeseriesSurrogates.jl ! Both packages provide tools about timeseries analysis and have a very common API and are in 1.0.

SignalDecomposition.jl allows one to decompose an input signal/timeseries into basic components. This is used for example to de-seasonalize a signal, or to do noise-reduction. TimeseriesSurrogates.jl is a package that creates surrogates. These are new timeseries created from the input timeseries that preserve some properties in the original timeseries and are used in hypothesis testing. Have a look at the docs for a more detailed information on surrogate timeseries!

Both packages have similar API: a function surrogate(s, method) or decompose(s, method) that makes surrogates / decomposes s via multiple dispatch on the method.

Hope they are useful!

19 Likes

Sweet animated logo :smiley:

2 Likes

It uses your method as well, so that should make you doubly happy :wink:

1 Like

for unending spam awesome packages.

8 Likes

Very nice! :+1:t2::pray:t2:

1 Like

Nice! Thanks for the announcement.

@Balinus, I have actually done some extentions of SignalDecomposition.jl in my private code, because I use it for climate data. E.g. I made it work with date times better, and also dispatch on DimensionalArrays. Maybe you are interested to talk about this.

Absolutely! This is an important aspect of climate analysis and I’ll certainly add this dep in ClimateTools. :grinning:

SignalDecomposition.jl now has several different methods for detrending and/or smoothing: Documentation · SignalDecomposition.jl

I also wanted to add a method based on Empirical Mode Decomposition, where a user specifies the first n modes to be taken as “trend” and the rest as residual. But I unfortunately didn’t find a codebase whose source code was explained enough in terms of what the keyword arguments mean. If anyone has a codebase that I can wrap or directly include in the repo I would appreciate it! The EMD method is broadly very useful.

5 Likes

I implemented EMD a few years ago and could look into reviving the package. Then we could wrap it in SignalDecomposition.jl

1 Like

Hi Felix, yes this sounds good. We are in fact using your codebase in a project with a student that gave birth to these new detrending methods (most of them are wraps). We are using your EMD code, but I felt that the codebase is not at a state that it can be wrapped in a registered package, so we left this method out of the online version. For me primarily the problem was understanding which entries in the returned vector are which modes, which modes have the most variance, and why the vector of modes returned has always an extra vector that is just zeros. If you are happy to update the codebase with docs regarding the keyword arguments and output type that would be great. The way I think of it is I’d like an EMD method that has two options: specify how many modes to decompose to, or specify an insignificance threshold for decomposition that when the last mode exceeds this threshold then the decomposition stops. I think in some papers people use an “explained variance” threshold. Then in SignalDecomposition.jl the user would specify what method to use to create the modes, and how many modes to keep as the “trend”. The rest become the residual.

1 Like