select_bwidth {deseats} | R Documentation |
Optimal Bandwidth Estimation for Locally Weighted Regression in Equidistant Time Series under Short Memory
Description
Optimal Bandwidth Estimation for Locally Weighted Regression in Equidistant Time Series under Short Memory
Usage
select_bwidth(
y,
smoothing_options = set_options(),
bwidth_start = NULL,
inflation_rate = c("optimal", "naive"),
correction_factor = FALSE,
autocor = TRUE,
drop = NULL,
error_model = c("free", "ARMA"),
nar_lim = c(0, 3),
nma_lim = c(0, 3),
arma_mean = FALSE
)
Arguments
y |
a numerical vector or a time series object of class |
smoothing_options |
an S4 object of class |
bwidth_start |
a single numeric value that is only relevant if the slot
|
inflation_rate |
a character vector of length one that indicates, which inflation rate
to use in the bandwidth selection; for a local linear trend, we have
|
correction_factor |
A logical vector of length one; theoretically, a
larger bandwidth to estimate the sum of autocovariances from residuals of
pilot trend and seasonality estimates is advisable than for estimating trend
and seasonality; for |
autocor |
a logical vector of length one; indicates whether to consider
autocorrelated errors ( |
drop |
a numeric vector of length one that indicates the proportion of
the observations to not include at each boundary in the bandwidth estimation
process, if a bandwidth is selected automatically; the default is
|
error_model |
a character vector of length one that indicates whether
for |
nar_lim |
only valid for |
nma_lim |
only valid for |
arma_mean |
only valid for |
Details
See further details in the documentation of the function
deseats
, where this function is applied internally
by default to select an optimal bandwidth.
Value
The function returns a list with different components:
bopt
the obtained optimal bandwidth.
bwidths
the obtained bandwidth for each iteration of the IPI-algorithm.
Imk
the final estimate of
I[m^{(k)}]
.sum_autocov
the final estimate of the sum of autocovariances.
Author(s)
Dominik Schulz (Research Assistant) (Department of Economics, Paderborn University),
Author and Package CreatorYuanhua Feng (Department of Economics, Paderborn University),
Author
References
Feng, Y. (2013). An iterative plug-in algorithm for decomposing seasonal time series using the Berlin Method. Journal of Applied Statistics, 40(2): 266-281. DOI: 10.1080/02664763.2012.740626.
Feng, Y., Gries. T, and Fritz, M. (2020). Data-driven local polynomial for the trend and its derivatives in economic time series. Journal of Nonparametric Statistics, 32(2): 510-533. DOI: 10.1080/10485252.2020.1759598.
Examples
Xt <- log(EXPENDITURES)
select_bwidth(Xt)