estimategr: estimategr

Description Usage Arguments Value

Description

A function used to estimate the reduced dimension regressions for g. The regression can be computed using a user specified function, passed through SL.gr or using SuperLearner when length(SL.gr) == 1 or is.list(SL.gr). There is an error proofing of the SuperLearner implementation that deals with situations where the NNLS procedure in the Super Learner ensemble fails and so the function returns zero weights for every coefficient. In this case, the code will default to using the discrete Super Learner; that is, the learner with lowest CV-risk.

Usage

1
2
estimategr(rg0, rg1, g0n, g1n, A0, A1, folds, validFold, Q2n, Q1n, SL.gr, abar,
  return.models, tolg, verbose, ...)

Arguments

rg0

The "residual" for the first reduced dimension regression (on Q1n).

rg1

The "residual" for the second reduced dimension regression (on Q2n).

g0n

A vector of estimates of g_0,0

g1n

A vector of estimates of g_1,0

A0

A vector treatment delivered at baseline.

A1

A vector treatment deliver after L1 is measured.

folds

Vector of cross-validation folds

validFold

Which fold is the validation fold

Q2n

A vector of estimates of Q_2,0

Q1n

A vector of estimates of Q_1,0

SL.gr

A vector or list specifying the SuperLearner library to be used to estimate the reduced-dimension regression to protect against misspecification of the treatment regressions. See SuperLearner package for details.

abar

A vector of length 2 indicating the treatment assignment that is of interest.

return.models

A boolean indicating whether the models for Qr0 should be returned with the output.

tolg

A numeric indicating the truncation level for conditional treatment probabilities.

Value

A list with elements g0nr, g1nr, h0nr, h1nr, and hbarnr, corresponding to the predicted values of the reduced dimension regressions. Also included in output are the models used to obtain these predicted values (set to NULL if return.models = FALSE)


benkeser/drinf documentation built on May 12, 2019, 11:59 a.m.