cr.exp.loss: Break down expected future optimality into two components: 1)...

Description Usage Arguments Value

View source: R/lopt nonmyop.R View source: R/lopt_nonmyop.R

Description

Break down expected future optimality into two components: 1) assuming that the current response is 0 2) assuming that the current response is 1 Find the weighted average of the two cases

Usage

1
2
cr.exp.loss(z.now, t.now, zp, N, design, k, beta, y, cr, wr, prior.scale, bayes,
  dyn = NULL, Nprobs = NULL, ...)

Arguments

z.now

vector of covariate values for current unit

t.now

treatment of current unit

zp

vector of probabilities for each level of covariate z (needs to in the same order as all.z below)

N

natural number greater than 0 for horizon

design

design matrix constructed for all units up until the current unit

k

number of covariates

beta

vector of current estimates for regression coefficients

y

vectir of responses generated up until current unit

cr

matrix of contrasts

wr

matrix of weights

prior.scale

prior scale parameter

bayes

set to T if bayesglm is used instead of glm. Default prior assumed

dyn

set to NULL of there are no dynamic covariates, set to T if there are dynamic covariates

Nprobs

a counter to be used if there are dynamic covariates

...

further arguments to be passed to <lossfunc>

Value

expected value of objective function one step ahead in the future


mst1g15/biasedcoin documentation built on Nov. 26, 2019, 4:01 a.m.