*! version 1.1.1

Title

kotlarski -- Executes deconvolution kernel density estimation and a robust construction of its uniform confidence band.

Syntax

kotlarski
x1
x2
[if] [in]
[, numx(real) domain(real) cover(real) tp(real) order(real) grid(real)]

Description

kotlarski executes deconvolution kernel density estimation and a robust construction of its uniform confidence band based on
Kato, Sasaki, and Ura (2021).
The command requires as input two measurements, x1 and x2, of the unobserved latent variable x with classical measurement errors, e1 = x1 - x and e2 = x2 - x, respectively.
The output consists of a deconvolution kernel density estimate of f(x) and their uniform confidence band over a domain of x.

FAQ: Why do kotlarski x1 x2 and kotlarski x2 x1 produce different results?
Answer: This is because Kotlarski's identity treats x1 and x2 asymmetrically in that x1 is assumed to have the zero mean of its measurement error, while x2 is not. See Assumption 1 in
Kato, Sasaki, and Ura (2021).

Options

numx(real) sets the number of grid points of x for deconvolution kernel density estimation and its uniform confidence band. The default value is numx(20).

domain(real) sets the domain of deconvolution kernel density estimation and its uniform confidence band. The default value domain(2) defines the domain as +/- 2 standard deviations of x.

cover(real) sets the nominal uniform coverage probability for the uniform confidence band. The default value cover(0.95) constructs a 95% uniform confidence band.

tp(real) sets the scale-normalized tuning parameter. Not invoking this option will entail an optimal choice of the tuning parameter.

order(real) sets the order q of the Hermite polynomial basis. The default value is order(2).

grid(real) sets the size L of grid in the frequency domain. The default value is grid(50).

Examples

(x1982 first measurement of x, x1983 second measurement of x)

Constructing a uniform confidence band in the domain corresponding to +/- 4 standard deviations of x:

. use "example_1982_1983.dta"

. kotlarski x1982 x1983, domain(4)

Construction of a 90% uniform confidence band:

. use "example_1982_1983.dta"

. kotlarski x1982 x1983, domain(4) cover(0.90)

Stored results

kotlarski stores the following in e():

Scalars

r(N) observations

r(h) tuning parameter

r(q) order of Hermite polynomial basis

r(L) grid size in frequency domain

Macros

r(cmd) kotlarski

Matrices

r(x) vector of x

r(fx) vector of density values

r(lower) confidence band (lower boundary)

r(upper) confidence band (upper boundary)

Reference

Kato, K., Y. Sasaki., and T. Ura 2021. Robust Inference in Deconvolution. Quantitative Economics, 12 (1): 109-142.
Link to Paper

Authors

Kengo Kato, Cornell University, Ithaca, NY.

Yuya Sasaki, Vanderbilt University, Nashville, TN.

Takuya Ura, University of California, Davis, CA.