-
Notifications
You must be signed in to change notification settings - Fork 0
appendix
The objective of this appendix is to describe the mechanics of information recovery from dynamic econometric models. All source code for our paper is open and written in Clojure, a new dialect of Lisp. This appendix will describe the estimation procedures through detailed documentation of the code.
Consider a time series of length T. Within the full time series there will be T - D + 1 sub-blocks of length D. The following illustration represents the D! ordinal patterns for sub-blocks when D = 3:
Note that the patterns do not reflect the values within the sub-blocks, but rather the ordinal relationships between the values in the sub-blocks. The permutation entropy method relies on the ordinal sequencing of sub-blocks, and the subsequent counts of the ordinal sub-sequences. The frequencies of sub-sequences reveal something about the dynamics of the time series. Consider an N length series, independently and identically distributed standard normal. The following is a simple plot of a series with N = 100.
The functional programming The code to extract the ordinal sub-sequences.
(defn- ordinal-idx
"Returns a sequence of indices that rank the values of the supplied
time series in ascending order. If there are equal values, the
lexicographic ordering kicks in and the order at which the values
appear is used to order the indices."
[sub-ts]
(let [indexed-vector (map-indexed vector sub-ts)]
(map first
(sort-by second indexed-vector))))


