Generates \(u_t = \Delta^{-d}\epsilon_t\),
\(\epsilon_t\) i.i.d. \((0, \sigma^2)\), via a
truncated \(MA(\infty)\) expansion of the fractional-differencing
operator, for use as sim_psy1(..., e = sim_fi(...)).
Arguments
- n
Number of innovations to generate.
- d
Long-memory (fractional differencing) parameter, in (0, 0.5) for \(u_t\) itself to be stationary.
- sigma
A positive scalar indicating the standard deviation of the innovations.
- seed
An object specifying if and how the random number generator (rng) should be initialized. Either NULL or an integer will be used in a call to
set.seedbefore simulation. If set, the value is saved as "seed" attribute of the returned value. The default, NULL, will not change rng state, and return .Random.seed as the "seed" attribute. Results are reproducible across the parallel and non-parallel option when the same seed is used.
Details
$$\Delta^{-d} = \sum_{j=0}^\infty \psi_j L^j,\quad \psi_0 = 1,\quad \psi_j = \psi_{j-1}\frac{j-1+d}{j}$$
truncated at max(200, n) lags with a matching burn-in (dropped
before returning) to limit truncation bias in the early observations.
References
Lui, Y.L., Phillips, P.C.B. & Yu, J. (2024). "Robust testing for explosive behavior with strongly dependent errors."
Examples
sim_fi(199, d = 0.2, seed = 1)
#> [1] -0.159211393 -0.836286373 -0.551308685 -1.633431674 -1.089916311
#> [6] 0.745323689 1.066501259 -0.728344183 0.087672025 0.025638368
#> [11] -1.696439773 0.437876306 -1.991634548 -1.719607346 0.434649792
#> [16] -0.739689819 -0.524948626 -1.914905579 -2.019481906 -0.349513543
#> [21] -0.616682675 -1.006596429 -1.809003411 -1.752882374 1.317275132
#> [26] -0.475165545 0.480792129 0.661984642 0.750532516 0.360767434
#> [31] -1.215545948 -1.283996635 0.347280666 -1.457335651 0.101742206
#> [36] -0.746008130 -0.713194493 -1.130332112 -0.670018961 0.484061493
#> [41] 0.299362468 -0.329799696 0.686876860 1.653533097 0.256604158
#> [46] 0.576667648 0.415473218 -0.857665488 -1.061445587 1.646333271
#> [51] 1.076131246 0.991929765 0.431340427 0.687262792 0.385998267
#> [56] 0.228599559 0.363736847 -0.860171674 2.309112944 1.246125646
#> [61] 0.176486986 1.451896027 -0.192555159 1.889047893 0.112300707
#> [66] -2.050261140 1.129890372 1.325712237 -0.415362066 -1.319475133
#> [71] -2.015788215 -0.710362211 -2.144225321 -1.394494106 -0.381876775
#> [76] 0.498060115 -0.941130622 -0.432822026 -0.009549765 1.549681415
#> [81] -0.777163318 -1.740864477 -2.271257529 -0.102655281 -0.402130544
#> [86] 0.463996538 -0.254200172 0.217097202 0.134771315 -0.045399434
#> [91] -0.710812337 1.040625560 -0.329158284 0.579498773 0.213643257
#> [96] 1.807595441 1.057798958 -0.007508169 0.129865931 -0.020809103
#> [101] -2.036611548 1.324953518 1.187720692 -0.507116516 0.377886804
#> [106] 0.329430383 -1.031038772 1.328789822 -0.040029185 0.246738233
#> [111] 0.486543729 -0.857984749 -1.194972752 -0.319946822 0.399526348
#> [116] 0.058294786 0.683262646 0.443934832 0.662258125 -1.227749967
#> [121] 0.504657311 -0.745542786 -0.608863040 -0.287687895 -1.794583227
#> [126] -0.542444356 -0.753980673 -1.048918574 -0.953811846 0.833256962
#> [131] -1.328438048 -0.587371870 -2.793688220 -1.432118644 -1.162378747
#> [136] 0.935895249 -1.136966056 -1.293927100 -1.919259085 -0.513080556
#> [141] 0.663159334 -1.391118249 -0.906346759 0.894072419 -0.804982737
#> [146] 0.362220902 0.244255212 -1.409293424 0.813360317 0.727908440
#> [151] -0.455016853 -1.049316713 -0.708790810 0.490155973 -0.664471161
#> [156] -2.122218304 -0.727705466 0.324153445 -1.369877098 -0.695499381
#> [161] -1.630862415 -0.472256809 -0.564000975 -0.438066023 -0.987224401
#> [166] -1.164745626 0.345993771 -0.150474038 -0.441115551 -3.508633492
#> [171] -2.193737692 -0.142133595 -0.943781540 -1.781451096 -1.179082980
#> [176] -1.059599514 -1.152622537 -0.163455662 1.053602080 0.839791665
#> [181] 1.196103997 -0.235718562 0.732586219 -0.955487249 -0.395882556
#> [186] 1.940139726 0.199752959 -0.263241071 -0.666744784 0.562123249
#> [191] 2.087212526 0.762625607 -0.018207241 2.153013547 -0.322558595
#> [196] 1.239318444 -0.110776065 -0.914128944 1.098456275
