avg_coverage_arima | R Documentation |
arima_pi
Computes expected coverage probabilities of the prediction intervals of ARMA process by simulating time series from the known model.
avg_coverage_arima(
phi = NULL,
theta = NULL,
d = 0,
n,
n_ahead = 1,
nsim2,
nsim = 100,
level = 0.95,
prior = "uniform",
return_all_coverages = FALSE,
...
)
phi |
vector containing the AR parameters |
theta |
vector containing the MA parameters |
d |
degree of differencing |
n |
length of the time series |
n_ahead |
length of the forecast horizon |
nsim2 |
number of simulations used in computing the expected coverage |
nsim |
number of simulations used in importance sampling |
level |
desired coverage probability of the prediction intervals |
prior |
prior to be used in importance sampling. Multiple choices are allowed. |
return_all_coverages |
return raw results i.e. coverages for each simulations. When |
... |
additional arguments to |
a list containing the coverage probabilities
arima_pi
.
## Not run:
set.seed(123)
# takes a while, notice se, increase nsim2 to get more accurate results
avg_coverage_arima(phi = 0.9, n = 50, n_ahead = 10, nsim2 = 100)
avg_coverage_arima(phi = 0.9, theta = -0.6, n = 50, n_ahead = 10, nsim2 = 100)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.