plot_cumulative_assignment {banditsCI} | R Documentation |
Plot cumulative assignment for bandit experiment.
Description
Generates a plot of the cumulative assignment.
Usage
plot_cumulative_assignment(results, batch_sizes)
Arguments
results |
List. Results of the experiment, including the actions taken ( |
batch_sizes |
Integer vector. Batch sizes used in the experiment. Must be positive integers. |
Value
A plot of the cumulative assignment.
Examples
set.seed(123)
A <- 1000
K <- 4
xs <- matrix(runif(A * K), nrow = A, ncol = K)
ys <- matrix(rbinom(A * K, 1, 0.5), nrow = A, ncol = K)
batch_sizes <- c(250, 250, 250, 250)
results <- run_experiment(ys = ys,
floor_start = 1/K,
floor_decay = 0.9,
batch_sizes = batch_sizes,
xs = xs)
plot_cumulative_assignment(results, batch_sizes)
[Package banditsCI version 1.0.0 Index]