Developer's documentation
This documentation addresses users that would like to contribute to the software by either solving bugs, improving documentation, or adding new methods. All contributions come in the form of Pull Requests, for which we strongly advise to follow good practices in scientific code, which means that they are properly formatted, documented, tested, etc.
New indicators or change metrics
As explained already in e.g., SlidingWindowConfig
, new indicators or change metrics are standard Julia functions, so you only need to define such a function (and document it, test it, etc.).
New pipeline for estimating changes
This means to contribute a fundamentally new "pipeline" for estimating/detecting transitions in timeseries. This new pipeline defines what a "transition" means. To add a new pipeline follow these steps:
- Define a new subtype of
ChangesConfig
- Define a new subtype of
ChangesResults
- Add a method for
estimate_changes
which accepts the newChangesConfig
subtype you defined and returns theChangesResults
subtype you defined.
And that's it!
Optionally you can further extend:
TransitionsInTimeseries.plot_indicator_changes
with the newChangesResults
type you defined. Note the plotting functions are in theext
folder of the repository.significant_transitions(res::ChangesResults, signif::Significance)
with your newChangesResults
type and as manySignificance
subtypes you have the capacity to extend for.
New pipeline for estimating significance
Statistically significant changes are "transitions". However, what "significant" means is not universal. There are different ways to test for significance and TransitionsInTimeseries.jl allows various methods.
To add a new pipeline for estimating significance follow these steps:
- Define a new subtype of
Significance
- Extend
significant_transitions(res::ChangesResults, signif::Significance)
with your new type and as manyChangesResults
subtypes as you have capacity for.
And that's it! Unfortunately so far we have found no way to make the significant_transitions
code agnostic of the changes result, so you would need to add a method manually for every ChangesResults
.
Optionally you can further extend TransitionsInTimeseries.plot_significance!
(which you can find in the ext
folder) for visualizing the significance results.