# LPPreg: Local Polynomial Regression at a point In kolesarm/RDHonest: Honest inference in sharp regression discontinuity designs

## Description

Calculate estimate and its variance given a bandwidth using local polynomial regression of order `order`.

## Usage

 ```1 2``` ```LPPreg(d, h, kern = "triangular", order = 1, se.method = "nn", no.warning = FALSE, J = 3) ```

## Arguments

 `d` object of class `"LPPData"` `h` Bandwidth. If not supplied, optimal bandwidth is computed according to criterion given by `opt.criterion`. `kern` specifies kernel function used in the local regression. It can either be a string equal to `"triangular"` (k(u)=(1-|u|)_{+}), `"epanechnikov"` (k(u)=(3/4)(1-u^2)_{+}), or `"uniform"` (k(u)= (|u|<1)/2), or else a kernel function. `order` Order of local regression 1 for linear, 2 for quadratic. `se.method` Vector with methods for estimating standard error of estimate. If `NULL`, standard errors are not computed. The elements of the vector can consist of the following methods: "nn"Nearest neighbor method "EHW"Eicker-Huber-White, with residuals from local regression (local polynomial estimators only). "demeaned"Use EHW, but instead of using residuals, estimate sigma^2_i by subtracting the estimated intercept from the outcome (and not subtracting the estimated slope). Local polynomial estimators only. "plugin"Plug-in estimate based on asymptotic variance. Local polynomial estimators in RD only. "supplied.var"Use conditional variance supplied by `sigma2` / `d` instead of computing residuals `no.warning` Don't warn about too few observations `J` Number of nearest neighbors, if "nn" is specified in `se.method`.

## Value

list with elements:

estimate

point estimate

se

Named vector of standard error estimates, as specified by `se.method`.

w

Implicit weight function used

sigma2

Estimate of sigma^2(X) for values of X receiving positive kernel weight. By default, estimates are based on squared regression residuals, as used in `"EHW"`. If `"demeaned"` or `"nn"` is specified, estimates are based on that method, with `"nn"` method used if both are specified.

eff.obs

Number of effective observations

kolesarm/RDHonest documentation built on Jan. 14, 2019, 7:04 a.m.