pygambit.gambit.MixedBehaviorProfile.__getitem__#

MixedBehaviorProfile.__getitem__()#

Access a component of the mixed behavior profile specified by index.

Parameters:

index (str or Selector) –

The part of the profile to return:

  • If index is a str, returns a MixedBehavior over the player’s information sets. The player is determined by finding the player with that label, if any.

  • If index is a Selector (an H-built expression) resolving to a single node, returns a MixedAction over the actions at that node’s information set.

Raises:
  • TypeError – If index is not a str or a Selector.

  • ValueError – If index is a Selector resolving to a terminal node, which belongs to no information set, or to a chance event.

  • KeyError – If index is a str and no player in the game has that label.