Cross prediction & Predictability improvement
You can add paths to CP and PI with install.m which permanently adds the path to CP and PI functions to MATLAB paths.
The two main functions CP_PI_CrossPrediction & CP_PI_PredictabilityImprovement compute causality measures between time series x, y for all parameters defined in the config file.
The config file consists of
L - number of time-series elements to predict
n - number of previous points of the manifold where to look for neighbours
TW - Taylor window
m.min, m.max - minimum and maximum value of m, the dimension of reconstruction (step 1)
tau.min, tau.max - minimum and maximum value of tau (step 1)
k.min, k.max - minimum and maximum value of k, number of nearest neighbours (step 1)
supp_w.no - number of weights of the supporting system in PI
supp_w.start - starting value of the weight of supporting system in PI
supp_w.step - step between values of weights of supporting system in PI
Configuration can be specified for methods and time series adding to CP or PI and X or Y.
Outputs of both methods consist of optimal values of m, tau, k for both time series, the mean absolute error for given predictions and the result of given methods. The PI output contains also the optimal weight of the supporting system.
Example of using both methods can be found in CP_PI_example.m
Running time of CP_PI_example.m on 4 CPUs is approx. 40 seconds.
You can find more info in:
KRAKOVSKÁ, Anna – JAKUBÍK, Jozef (2020). Implementation of two causal methods based on predictions in reconstructed state spaces. In Physical Review E, vol. 102, p. 022203
Krakovska, A.; Hanzely, F. Testing for causality in reconstructed state spaces by an optimized mixed prediction method. Physical Review E 2016, 94 (5), 052203.
Krakovska, A.; Jakubik, J.; Chvostekova, M.; Coufal, D.; Jajcay, N.; Palus, M. Comparison of six methods for the detection of causality in a bivariate time series. Physical Review E 2018, 97 (4), 042207.
Jozef Jakubik (2023). Cross Prediction and Predictability Improvement (https://www.mathworks.com/matlabcentral/fileexchange/75057-cross-prediction-and-predictability-improvement), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform CompatibilityWindows macOS Linux
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!