The `nekd()` function enables to implement the naive kernel density estimation without bias correction for the heterogeneous mean, the autocovariance, and the autocorrelation. The method is developed by Okui and Yanagi (2020). For more details, see the package vignette with `vignette("panelhetero")`.
nekd(
data,
acov_order = 0,
acor_order = 1,
mean_bw = NULL,
acov_bw = NULL,
acor_bw = NULL
)
A list that contains the following elements:
A plot of the corresponding density
A plot of the corresponding density
A plot of the corresponding density
A function that returns the corresponding density
A function that returns the corresponding density
A function that returns the corresponding density
A Vector of the bandwidths
A matrix of the estimated heterogeneous quantities
The order of autocovariance
The order of autocorrelation
The number of cross-sectional units
The length of time series
A matrix of panel data. Each row corresponds to individual time series.
A non-negative integer of the order of autocovariance. Default is 0.
A positive integer of the order of autocorrelation. Default is 1.
A scalar of bandwidth used for the estimation of the denisty of mean. Default is NULL, and the plug-in bandwidth is used.
A scalar of bandwidth used for the estimation of the denisty of autocovariance. Default is NULL, and the plug-in bandwidth is used.
A scalar of bandwidth used for the estimation of the denisty of autocorrelation. Default is NULL, and the plug-in bandwidth is used.
Okui, R. and Yanagi, T., 2020. Kernel estimation for panel data with heterogeneous dynamics. The Econometrics Journal, 23(1), pp.156-175.
data <- panelhetero::simulation(N = 300, S = 50)
panelhetero::nekd(data = data)
Run the code above in your browser using DataLab