Homepage Demos Overview Downloads Tutorials Reference
Credits

karmedbanditExp3_1 Class Reference

#include <karmedbandit.h>

List of all members.


Detailed Description

Makes decisions regarding an adversarial k-armed bandit.

Uses algorithms described in: The non-stochastic multi-armed bandit problem Auer, Cesa-Bianchi, Freund, and Schapire October 14, 2002

Definition at line 84 of file karmedbandit.h.

Public Member Functions

 karmedbanditExp3_1 (unsigned int k)
 constructor, pass the number of arms

unsigned int decide ()
 returns the next choice, [0:k-1]

void reward (bool rew)
 call this if you want to reward (r==true) or penalize (r==false) the previous decision


Protected Member Functions

void restart ()
 restarts exp3


Protected Attributes

unsigned int r
 the number of restarts

double gr
 the gamma_r parameter

unsigned int last
 the last choice

std::vector< double > G
 the G-hat's

karmedbanditExp3 exp3
 runs exp3 within this


Constructor & Destructor Documentation

karmedbanditExp3_1::karmedbanditExp3_1 unsigned int  k  )  [inline]
 

constructor, pass the number of arms

Definition at line 87 of file karmedbandit.h.


Member Function Documentation

unsigned int karmedbanditExp3_1::decide  )  [inline]
 

returns the next choice, [0:k-1]

Definition at line 94 of file karmedbandit.h.

Referenced by BanditMachine::DecideNode::DoStart().

void karmedbanditExp3_1::restart  )  [inline, protected]
 

restarts exp3

Definition at line 113 of file karmedbandit.h.

Referenced by decide(), and karmedbanditExp3_1().

void karmedbanditExp3_1::reward bool  rew  )  [inline]
 

call this if you want to reward (r==true) or penalize (r==false) the previous decision

Definition at line 106 of file karmedbandit.h.

Referenced by BanditMachine::WaitNode::DoStop().


Member Data Documentation

karmedbanditExp3 karmedbanditExp3_1::exp3 [protected]
 

runs exp3 within this

Definition at line 127 of file karmedbandit.h.

Referenced by decide(), karmedbanditExp3_1(), restart(), and reward().

std::vector<double> karmedbanditExp3_1::G [protected]
 

the G-hat's

Definition at line 126 of file karmedbandit.h.

Referenced by decide(), karmedbanditExp3_1(), and reward().

double karmedbanditExp3_1::gr [protected]
 

the gamma_r parameter

Definition at line 124 of file karmedbandit.h.

Referenced by decide(), karmedbanditExp3_1(), and restart().

unsigned int karmedbanditExp3_1::last [protected]
 

the last choice

Definition at line 125 of file karmedbandit.h.

Referenced by decide(), karmedbanditExp3_1(), and reward().

unsigned int karmedbanditExp3_1::r [protected]
 

the number of restarts

Definition at line 123 of file karmedbandit.h.

Referenced by karmedbanditExp3_1(), and restart().


The documentation for this class was generated from the following file:
Tekkotsu v2.0
Generated Wed Jan 21 03:23:15 2004 by Doxygen 1.3.4