Draws arms from a LinTS or non-contextual TS agent for multi-armed bandit problems.
draw_thompson(model, start, end, xs =NULL)
Arguments
model: List. Contains the parameters of the model, generated by LinTSModel().
start: Integer. Starting index of observations for which arms are to be drawn. Must be a positive integer.
end: Integer. Ending index of the observations for which arms are to be drawn. Must be an integer greater than or equal to start.
xs: Optional matrix. Covariates of shape [A, p], where p is the number of features, if the LinTSModel is contextual. Default is NULL. Must not contain NA values.
Returns
A list containing the drawn arms (w) and their corresponding probabilities (ps).