This program estimates the correlation sum, the correlation dimension and the correlation entropy of a given, possibly multivariate, data set. It uses the box assisted search algorithm and is quite fast as long as one is not interested in large length scales. All length scales are computed simultaneously and the current center and epsilon are written every 2 min (real time, not cpu time) or every set number of center value increases. It is possible to set a maximum number of pairs. If this number is reached for a given length scale, the length scale will no longer be treated for the rest of the estimate.
Input
This function always assumes that each time series is along the longer dimension of matrix S. It also assumes that every dimension (counting along the shorter dimension) of S is considered a component of the time series.
Parameters
The maximum embedding dimension [default = 10].
The delay used [default = 1].
Theiler window [default = 0].
Minimum length scale [default = 1e-3].
Maximum length scale [default = 1].
Number of length scale values [default = 100].
Maximum number of pairs to be used (value 0 means all possible pairs) [default = 1000].
This parameter determines after how many iterations (center points) should the program pause and write out how many center points have been treated so far and the current epsilon. If plot_corr or plot_slopes or plot_entrop is set then during the pause a plot of the current state of c2, d2 or h2 (respectively) is produced. Regardless of the value of this parameter the program will pause every two minutes [default = only pause every 2 minutes].
Switches
When this switch is set the program uses data normalized to [0,1] for all components.
If this switch is set then whenever the execution is paused (the frequency can be set with parameter p) the most recent correlation sums are plotted. The color used for them is blue.
Same as plot_corr except the plotted values are the local slopes. They are plotted in red.
Same as plot_corr except the correlation entropies are plotted. They are plotted in green.
Output
This is a struct array that contains the following fields:
This is a struct. It contains the following fields:
See also: demo d2, av_d2, c2t, c2g.
Algorithms
The algorithms for this functions have been taken from the TISEAN package.
The following code
vals = d2 (henon (1000), 'd', 1, 'm', 5, 't',50); subplot (2,3,1) do_plot_corr = @(x) loglog (x{1}(:,1),x{1}(:,2),'b'); hold on arrayfun (do_plot_corr, {vals.c2}); hold off axis tight xlabel ("Epsilon") ylabel ("Correlation sums") title ("c2"); subplot (2,3,4) do_plot_entrop = @(x) semilogx (x{1}(:,1),x{1}(:,2),'g'); hold on arrayfun (do_plot_entrop, {vals.h2}); hold off axis tight xlabel ("Epsilon") ylabel ("Correlation entropies"); title ("h2") subplot (2,3,[2 3 5 6]) do_plot_slope = @(x) semilogx (x{1}(:,1),x{1}(:,2),'r'); hold on arrayfun (do_plot_slope, {vals.d2}); hold off axis tight xlabel ("Epsilon") ylabel ("Local slopes") title ("d2");
Produces the following figure
Figure 1 |
---|
Package: tisean