Code and Results for Chapter 2:

These are results and code for the problems and examples found in Chapter 2 of this famous book.

Various Figures and Problems:
  1. sample_discrete.m (Utility function to sample from a discrete distribution)
  2. n_armed_testbed.m (Matlab code to generate the n-armed bandit testbed)
  3. n_armed_testbed_softmax.m (Matlab code to generate the softmax n-armed bandit)
  4. The Binary Bandit:
  5. exercise_2_5.m (Exercise 2.5)
  6. Exercise 2.7:
  7. Optimistic Initial Values:
  8. Reinforcement Comparison Methods:
  9. Exercise 2.11:
  10. Pursuit Methods:

John Weatherwax