mab_sim: (Contextual) MAB Simulation

Description Usage Arguments

View source: R/mab_sim.R

Description

(Contextual) MAB Simulation

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
mab_sim(
  nsteps,
  reward_funs,
  sd,
  J,
  alpha = 1,
  a = 3,
  b = 1,
  repartition = TRUE
)

Arguments

nsteps

The number of steps (decisions) in the simulation.

reward_funs

A list of functions givin the expected reward of each earm (given context x).

sd

A numeric vector giving the standard deviation of each lever.

J

The number of basis functions to be used in the model.

alpha

A scaling parameter for the prior variances. The prior variance of the i'th model coefficient is given by i^-alpha (the intercept is the 0'th coefficient, and has a prior variance of 1).

a

The shape parameter for the inverse gamma distribution.

b

The scale parameter for the inverse gamma distribution.

repartition

Set to FALSE if you don't want to partition the context space.


dfcorbin/MABsim documentation built on April 26, 2020, 8:26 a.m.