make_plr_CCDDHNR2018 {DoubleML}R Documentation

Generates data from a partially linear regression model used in Chernozhukov et al. (2018)

Description

Generates data from a partially linear regression model used in Chernozhukov et al. (2018) for Figure 1. The data generating process is defined as

di=m0(xi)+s1vi,d_i = m_0(x_i) + s_1 v_i,

yi=αdi+g0(xi)+s2ζi,y_i = \alpha d_i + g_0(x_i) + s_2 \zeta_i,

with viN(0,1)v_i \sim \mathcal{N}(0,1) and ζiN(0,1),\zeta_i \sim \mathcal{N}(0,1),. The covariates are distributed as xiN(0,Σ)x_i \sim \mathcal{N}(0, \Sigma), where Σ\Sigma is a matrix with entries Σkj=0.7jk\Sigma_{kj} = 0.7^{|j-k|}. The nuisance functions are given by

m0(xi)=a0xi,1+a1exp(xi,3)1+exp(xi,3),m_0(x_i) = a_0 x_{i,1} + a_1 \frac{\exp(x_{i,3})}{1+\exp(x_{i,3})},

g0(xi)=b0exp(xi,1)1+exp(xi,1)+b1xi,3,g_0(x_i) = b_0 \frac{\exp(x_{i,1})}{1+\exp(x_{i,1})} + b_1 x_{i,3},

with a0=1a_0=1, a1=0.25a_1=0.25, s1=1s_1=1, b0=1b_0=1, b1=0.25b_1=0.25, s2=1s_2=1.

Usage

make_plr_CCDDHNR2018(
  n_obs = 500,
  dim_x = 20,
  alpha = 0.5,
  return_type = "DoubleMLData"
)

Arguments

n_obs

(integer(1))
The number of observations to simulate.

dim_x

(integer(1))
The number of covariates.

alpha

(numeric(1))
The value of the causal parameter.

return_type

(character(1))
If "DoubleMLData", returns a DoubleMLData object. If "data.frame" returns a data.frame(). If "data.table" returns a data.table(). If "matrix" a named list() with entries X, y and d is returned. Every entry in the list is a matrix() object. Default is "DoubleMLData".

Value

A data object according to the choice of return_type.

References

Chernozhukov, V., Chetverikov, D., Demirer, M., Duflo, E., Hansen, C., Newey, W. and Robins, J. (2018), Double/debiased machine learning for treatment and structural parameters. The Econometrics Journal, 21: C1-C68. doi:10.1111/ectj.12097.


[Package DoubleML version 1.0.1 Index]