tmle_parallel: Modify TMLE to support parallel computation for g and Q.

Description Usage Arguments See Also

View source: R/tmle_parallel.R

Description

This is needed to use Savio or any multicore system effectively.

Another benefit is that the SuperLearner objects for the Q and g estimation are saved. This allows one to examine the risk estimates for example.

Usage

1
2
3
4
tmle_parallel(Y, A, W, family, g.SL.library, Q.SL.library, id = 1:length(Y),
  verbose = F, V = 5, sl_fn = SuperLearner::SuperLearner,
  cvsl_fn = SuperLearner::CV.SuperLearner, cvQinit = F,
  conserve_memory = T, ...)

Arguments

Y

Outcome

A

Treatment indicator

W

Covariates

family

Gaussian or binomial

g.SL.library

SL library for estimating g

Q.SL.library

SL library for estimating Q

id

Optional list of subject-specific ids.

verbose

If TRUE outputs additional information during execution.

V

Number of cross-validation folds to use when estimating g and Q. Defaults to 5 as tmle package does.

sl_fn

SuperLearner function to use for estimation of g and possibly Q. By default this uses the normal SuperLearner function which is sequential. Other options would be to pass in mcSuperLearner, snowSuperLearner, or CV.SuperLearner. For functions that require additional arguments (e.g. the cluster argument of for snowSuperLearner) one should create a new function that overloads the call and sets that argument. This is what setup_parallel_tmle() does.

cvsl_fn

CV.SuperLearner equivalent, can be used for estimating Q.

cvQinit

If T, estimate Q using cvsl_fn, otherwise use sl_fn.

conserve_memory

If T, remove the fitLibrary elements to save memory after we have done the relevant prediction.

...

Remaining arguments are passed through to tmle::tmle().

See Also

setup_parallel_tmle


ck37r documentation built on June 4, 2017, 1:02 a.m.