weighted_ordinal_pattern_distribution: A function to compute weighted ordinal pattern statistics In statcomp: Statistical Complexity and Information Measures for Time Series Analysis

Description

Computation of weighted ordinal patterns of a time series. Weights can be generated by a user-specified function (e.g. variance-weighted, see Fadlallah et al 2013).

Usage

 `1` ```weighted_ordinal_pattern_distribution(x, ndemb) ```

Arguments

 `x` A numeric vector (e.g. a time series), from which the weighted ordinal pattern distribution is to be calculated `ndemb` Embedding dimension of the ordinal patterns (i.e. sliding window size). Should be chosen such as length(x) >> ndemb

Details

This function returns the distribution of weighted ordinal patterns using the Keller coding scheme, detailed in Physica A 356 (2005) 114-120. NA values are allowed. The function uses old and slow R routines and is only maintained for comparability. For faster routines, see weighted_ordinal_pattern_distribution.

Value

A character vector of length factorial(ndemb) is returned.

Sebastian Sippel

References

Fadlallah, B., Chen, B., Keil, A. and Principe, J., 2013. Weighted-permutation entropy: A complexity measure for time series incorporating amplitude information. Physical Review E, 87(2), p.022911.

`weighted_ordinal_pattern_distribution`

Examples

 ```1 2``` ```x = arima.sim(model=list(ar = 0.3), n = 10^4) weighted_ordinal_pattern_distribution(x = x, ndemb = 6) ```

Example output

```  [1] 35.1209130 28.5170067 27.2697483 24.9689948 25.1198458 11.5886040
[7] 27.5309845 12.9848797 45.3443771 31.3197923 12.5154578 14.3989571
[13] 11.6360282 13.9437976 30.3331540 29.6765890 25.2665533 17.5155359
[19]  7.3632532 12.3683906  8.6545123  9.9637387 18.0213507 16.4023793
[25]  4.7488853  6.8366009  4.7809144  8.5824980 14.3807481 24.6840268
[31] 26.7996915 11.7318864 18.8396026 13.4197722  9.0071136 14.5347591
[37] 17.3611373  3.6040206  8.3471890 14.2325918 19.8435298  9.7573870
[43] 24.4311176 18.8250351 16.8906408 28.6210958 24.0897279 22.3399754
[49]  8.5375725  8.6743653 11.2562648 10.2986377 15.4741318 17.2736540
[55]  4.4106275  5.8153301 13.2812979  7.6843866 12.4229269 23.0383680
[61] 12.8539735 10.5792353 10.5417385  7.4871112  4.4657572  2.9246969
[67] 11.3164354  7.6484541  7.0976271 10.1162948  6.0158522  8.2585371
[73] 10.2271679 10.0958164  7.5052580  7.4448603  8.4550747  8.5420239
[79]  9.1703486  9.8541772 14.0944658 19.1443026  8.1066467 21.4136953
[85]  9.6915959  6.3751024 10.0258539 20.0448876 16.2230158 29.9021678
[91] 18.3433465  4.1354301  1.6356447  3.8977091  0.7961022  5.0023420
[97]  7.3834077  4.7608655  2.8601137  5.8203051  6.1135089  5.1268603
[103] 11.6940100  3.5089820  3.5567403  6.5187226  5.3715028 10.7216812
[109]  5.3022955  7.3161049 13.7963613 20.7505360  9.4506635 14.4222051
[115]  8.6319109 13.4833067 12.2409263 19.7817091 27.2418570 29.5184897
[121] 25.8624892 27.9853316 29.9118856  9.4268062 15.5422288 15.8477606
[127] 12.5181780 10.6706295 10.8778658  8.5287317 13.1711853  7.9281410
[133]  5.0619575  6.5737501  5.9935029  9.5975092  6.2241719  6.9461358
[139]  9.9386764  4.5090062  2.9013164  6.7255560  7.2244252 12.9986012
[145]  5.5713437  4.7460412  7.4289013  5.2742952 12.1902938 12.5548832
[151] 19.2046889 17.9598404  5.2543673  3.8754050  3.1321197  9.5946678
[157]  5.5468496  4.7882147  2.5670693  5.1039326  5.5754275  2.8962079
[163]  2.9995874  7.2587284  4.2995215  4.0830989  7.3934924  9.4559952
[169]  4.7869742  5.7500695  1.6846159  7.2396724 14.3836267 11.1362194
[175]  6.2315744  3.8684823  4.8141987 12.9758471  9.7581664 18.8167119
[181] 16.8553549 11.0156107  9.2031767  7.2467628  4.9338128  5.3632388
[187] 13.3478030  3.6669982  4.0013900  7.9354016  8.3678706  8.9457136
[193]  6.9078676  5.7591493  9.7189809  9.4232175  5.0822622  7.5838827
[199]  4.2566860  4.9771655 12.4549862  9.4282958 14.9095871 13.4437326
[205]  6.7735724  7.9101707  9.4819733 16.8692083 27.6690307 18.1314945
[211]  5.8628490  7.7898534  3.2157202  6.6340937  7.3835295  6.4253159
[217] 10.8861956  6.5812678  6.9101767  8.3230395  3.4215342  5.0449765
[223]  5.7289833  6.9645163  6.7737635 10.4645643 11.3166709  8.9626071
[229] 12.5602147  8.1838345 11.3272876 19.2501948  7.5747769 19.9500813
[235]  8.1303572  8.4725885 12.9382518 25.0920699 32.4886318 20.9772632
[241] 26.9155888 17.7415601 13.5193079  7.4829115  5.2474072  2.0950005
[247] 11.6777702  7.3537787  9.0991449  6.4124923  6.3387554  8.3073196
[253]  9.9865662  7.5744737  4.8361629  6.6313819  2.2755114  4.6885269
[259]  4.6353870  3.5151573  2.6608469  1.5185920  2.6770252  7.8523177
[265]  4.5319270  3.7463981  3.3170378  0.6466043  9.5359557 10.9306823
[271] 19.8269637  6.1270240  6.7168459  4.4258462  3.0000098  3.9981561
[277]  8.5920166  5.8774418  5.8815020  3.1714171  5.5903779  2.2921633
[283]  6.6448022  1.8478074  3.1838236  3.4513578  6.9712095  7.0149844
[289]  5.2862791  5.1925710  5.5492605  6.9064212  3.0561801 14.1128576
[295]  7.3014404  1.6832178  3.0846099  8.6876544 11.6925399 11.8633406
[301] 20.3239662 13.3869156  4.7421063 10.2674605  5.8281637  7.5892773
[307] 15.2060112  9.7274292  7.9349396  5.8724071  4.0768784  7.0736349
[313]  9.3729176 11.6001941 18.5938923  8.6012679  9.1229656 15.2862100
[319]  4.8063084  3.8047911 14.0224133  8.1581934  8.6655204 13.7615127
[325]  5.9092009  4.3981782 10.4010155  9.4454393 16.2932788 20.0840573
[331] 15.9608698 20.4306775  7.4431607  4.2527446  7.7158053  4.1302094
[337] 23.2049987  6.6856140  8.0971991 11.6752237  4.8665418 14.1632569
[343]  8.8595116 10.7665301 21.6593473 13.1227780 13.2928453 18.6539387
[349] 15.9088922 16.5730100 16.7772374 29.9563051 27.4314551 23.5313781
[355] 16.6898597 10.1568770 16.5366310 26.6557984 33.3757817 31.5321349
[361] 32.0548583 35.3574444 32.0418756 19.2652336 11.4821985  7.0290823
[367] 20.1968471 18.1117066 41.8175555 15.1718126 13.1982829 11.5987973
[373] 14.0367224 14.3300494  8.1293336 11.4269350 15.4265620 17.3892696
[379]  6.1556527  8.5630747  6.3342873  8.7247626 13.0554831 12.7621986
[385]  3.8328630  4.7150930  7.5094507  4.6397605 19.0579702 17.6530478
[391] 32.5744073 17.3973878  9.7767070  5.8826174  3.5351979  4.0555956
[397] 12.9083993  3.7066744  5.3404706 10.0859220  5.9782773  8.3636444
[403] 13.2926440 11.2125418 10.7174341 12.0511540 10.5155244 13.7403212
[409]  6.0756551  5.6292796  8.7168647  6.2822847  4.7839214 13.1709468
[415]  5.5248841  5.7979099  4.9867517  6.9594110 13.2675038 20.7582850
[421] 14.1433587  9.8896554  8.5394873  5.1474885  6.9834805  5.3862901
[427]  5.2986212  6.4968789  9.0237059  3.3267998  2.3297010  5.1039461
[433]  8.1972936  5.2425847  3.0460600  5.3012660  5.1516304  8.2316341
[439]  4.7117951  4.1191076  5.1204872  2.3290207  4.6425767  6.8314992
[445]  4.0899797  4.7513672  5.9341110  9.5954581 14.1951769 13.5596434
[451] 11.6897449  9.6686920  9.1139474  2.6466160  5.0933950  4.8885603
[457]  6.8710538  3.2294488  6.5292781  1.5107479  5.2987406  6.0162369
[463]  2.9628681  6.7914769  3.1973397  3.7848241  7.2623938  5.1606124
[469] 11.0906344  6.3227462  8.9577227 13.3964945  8.2961408 10.6934876
[475]  6.8602872 12.6079223  9.1030338 15.9112996 22.9130718 13.4459796
[481] 34.8370144 23.1912402 34.0914419 19.7707883  8.7510113  6.3899459
[487] 21.6359023 16.5961024 19.4134671 13.0109934  7.8803539 10.2242420
[493] 10.2885559 11.5579260  5.8029123  7.6271100  3.2879614  8.2505724
[499]  4.6098370  4.4172806  3.7078658  1.9991004  6.9370432  9.8930633
[505]  1.1399343  1.3509878  5.7456050  6.9821256  8.0758623 16.0354911
[511] 25.7680990 25.8117913 17.8635380 11.6928684  4.9914711  3.9903662
[517] 12.3506078 10.9440485 18.5431574  9.5276424  5.5190079  8.8572265
[523]  6.1533653  9.7321058  5.7262592 11.0022409  4.9354135 10.7510261
[529]  9.6837819  5.0530177  6.7187558  3.1566858  6.4919478  8.2920048
[535]  4.7198428 11.0089622  3.3683565  4.7952767 10.0097729  8.6582982
[541] 21.1306763 12.3060098  4.2363557  1.5673765  6.4807889  6.1992594
[547] 19.8498046  4.2311949  6.5225303  4.7056368  7.0724330  6.7366316
[553] 10.4270557  3.5520449  4.9792157  2.3770509 10.8316743  5.5702951
[559]  4.9556253  5.6202306  4.3815235  5.0289847  8.3564232  9.4847043
[565]  6.3590222 13.0932896 10.1510483  4.4742243 20.4763457 18.5660821
[571] 12.4968352 13.3714751  3.3454232  8.0550356  2.7247927  6.3512235
[577]  8.3202882  4.9490641  5.8701985  4.2304967  4.7312747  8.2258889
[583]  6.7219439  7.1134445  5.6021551  5.1148427  4.2166693 12.7827286
[589]  9.8550506  9.7898406 12.4154164 10.9742304 20.1501267 12.3096647
[595]  8.8398580 18.7668711  8.3953098 12.7666632 24.0155662 22.8605636
[601] 21.0450443 26.2580875 12.5732984  5.4093547 10.8914734  5.8918538
[607] 13.2104045  5.8182733 20.4054977  9.8634741  8.6171402 12.9941584
[613]  8.6708413  5.9195304  4.7404241  9.0525713  5.2367203  5.3216983
[619]  9.1056870  5.7104100  3.7398599 11.8228379  3.6710705 10.3778858
[625]  5.9410259  2.6092421  1.9044290  7.5302931  9.3549069 15.5700888
[631] 31.9767288 20.8816144 15.0560935 12.6984154 10.5141772  7.8432266
[637] 13.9410674 15.7644540 11.9989027 11.0761089  9.9281595  5.9685919
[643]  6.7416309  9.8832243 12.2475697  7.9513820  9.5515401  9.6133197
[649] 11.6448435  8.2438065  4.6851289  6.8739650  8.8928290 15.5565450
[655]  6.9575605  7.0050056 10.9781723  7.5395905 15.9865403 26.1689467
[661] 25.9809335 21.8932025 15.1230352  8.6789650  4.4631167  3.2341900
[667] 20.8037623 15.2538226 16.2486269 10.5069285 10.7537073  8.0306509
[673] 28.2652174 23.0624951 14.5613288 20.1536869 15.3485773 11.1058212
[679] 14.1238494 12.6749629 18.2375078  7.8837276 10.6031456 22.8756422
[685]  7.5404642 13.9559405 11.6067291 10.5262934 21.8627603 18.6745788
[691] 13.7302745 10.9491951 10.5697239  7.9766717  6.4185228  4.9739268
[697] 18.0944616  9.9590908 11.4028426 11.3677097  5.9253235 13.6364128
[703] 14.5487736 26.2766802 19.0249346 16.2844089 19.9230368 14.9176742
[709] 20.4782843 12.2295738 28.8312608 39.1748043 21.0265860 22.0293753
[715]  6.2237565  7.3864153 20.1067050 33.0470349 25.0596236 44.8354463
```

statcomp documentation built on Oct. 30, 2019, 11:15 a.m.