Learn R Programming

whatifbandit (version 0.3.0)

print.multiple.mab: Print Generic For multiple.mab

Description

Custom Print Display for multiple.mab objects returned by multiple_mab_simulation(). Prevents the large list output from being printed directly, and provides useful information about the settings for the trials.

Usage

# S3 method for multiple.mab
print(x, ...)

Value

Text summary of settings used for the Multi-Arm Bandit trials.

Arguments

x

A multiple.mab class object created by multiple_mab_simulation().

...

Further arguments passed to or from other methods.

Details

The items used to create the text summary can be found in the settings element of the output object.

... is provided to be compatible with print(), no other arguments change output.

Examples

Run this code
# Running Multiple Simulations
x <- multiple_mab_simulation(
  data = tanf,
  algorithm = "thompson",
  assignment_method = "Batch",
  period_length = 1750,
  prior_periods = "All",
  blocking = FALSE,
  whole_experiment = TRUE,
  perfect_assignment = TRUE,
  data_cols = c(
    id_col = "ic_case_id",
    success_col = "success",
    condition_col = "condition"
  ),
  times = 5, seeds = sample.int(5)
)
print(x)

Run the code above in your browser using DataLab