Metadata-Version: 2.1
Name: banditsbook
Version: 0.1.1
Summary: Python code from the book Bandit Algorithms for Website Optimization
Home-page: https://gitlab.com/winderresearch/rl/BanditsBook/
Author: Phil Winder
Author-email: phil@WinderResearch.com
License: UNKNOWN
Project-URL: Bug Reports, https://gitlab.com/winderresearch/rl/BanditsBook/issues
Project-URL: Source, https://gitlab.com/winderresearch/rl/BanditsBook/
Keywords: rl bandits abtesting
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Requires-Python: >=3.5
Description-Content-Type: text/markdown

# Bandit Code for the Book "Reinforcement Learning"

This repository was forked from [John Myles White's "BanditsBook" repository](https://github.com/johnmyleswhite/BanditsBook).

I have removed all the non-python code and added a setup.py file to allow for pip installs. Everything else is the same.

## Installing

```
pip install banditsbook
```

## Getting Started

```
from arms.bernoulli import BernoulliArm
from testing_framework.tests import test_algorithm
from algorithms.epsilon_greedy.standard import EpsilonGreedy
num_sims = 1000
horizon = 10

arm0 = BernoulliArm(0.2)
arm1 = BernoulliArm(0.2)
arms = [arm0, arm1]
algo1 = EpsilonGreedy(0.1, [], [])
sim_nums, times, chosen_arms, rewards, cumulative_rewards = test_algorithm(
    algo1, arms, num_sims, horizon)
print(rewards)
```

See the original repository for more information: https://github.com/johnmyleswhite/BanditsBook

Icons made by <a href="https://www.flaticon.com/authors/good-ware" title="Good Ware">Good Ware</a> from <a href="https://www.flaticon.com/" title="Flaticon"> www.flaticon.com</a>

