Compute (Overnight) Cumulative Intraday Returns
cidr.Rd
Compute (Overnight) Cumulative Intraday Returns
Arguments
- X
A dfts object or data which can be automatically converted to that format. See
dfts()
.
References
Rice, G., Wirjanto, T., & Zhao, Y. (2023). Exploring volatility of crude oil intraday return curves: A functional GARCH-X model. Journal of Commodity Markets, 32, 100361-.
Examples
tmp <- dfts(SPYUS500$data[, 1:100],
name = "SP500 100 Days",
labels = SPYUS500$labels[1:100], fparam = SPYUS500$fparam
)
cidr(tmp)
#> CIDR of SP500 100 Days
#> dimension: 390 x 100
#> season: 1
#> fparam (390): 0 0.002570694 0.005141388 0.007712082 0.01028278 0.01285347 ...
#> labels (100): 17898 17899 17900 17903 17904 17905 ...
#>
#> Example data
#> [,1] [,2] [,3] [,4] [,5] [,6]
#> [1,] 0.000000000 0.00000000 0.00000000 0.00000000 0.00000000 0.00000000
#> [2,] 0.162811270 0.03220132 -0.11756508 -0.03523601 -0.01168033 -0.05786352
#> [3,] 0.093821401 -0.04791866 -0.12120332 -0.01543897 0.03542200 -0.08117372
#> [4,] 0.125887319 -0.09223365 -0.01251754 0.05579794 0.00000000 -0.00776497
#> [5,] 0.073115156 -0.12890908 -0.08886807 -0.01148003 0.02374580 0.02756077
#> [6,] 0.008532857 -0.19705631 -0.08482690 -0.22945470 0.03153009 0.03105385
tmp <- dfts(SPYUS500$data[, 1:100],
name = "SP500 100 Days",
labels = SPYUS500$labels[1:100], fparam = SPYUS500$fparam
)
ocidr(tmp)
#> OCIDR of SP500 100 Days
#> dimension: 390 x 100
#> season: 1
#> fparam (390): 0 0.002570694 0.005141388 0.007712082 0.01028278 0.01285347 ...
#> labels (100): 17898 17899 17900 17903 17904 17905 ...
#>
#> Example data
#> [,1] [,2] [,3] [,4] [,5] [,6]
#> [1,] 0.000000000 -0.7264299 1.456442 0.07523799 1.013461 0.3301546
#> [2,] 0.162811270 -0.6942286 1.338877 0.04000198 1.001781 0.2722911
#> [3,] 0.093821401 -0.7743486 1.335239 0.05979902 1.048883 0.2489809
#> [4,] 0.125887319 -0.8186636 1.443925 0.13103593 1.013461 0.3223896
#> [5,] 0.073115156 -0.8553390 1.367574 0.06375796 1.037207 0.3577154
#> [6,] 0.008532857 -0.9234862 1.371615 -0.15421671 1.044991 0.3612084