egttools.behaviors.NormalForm.TwoActions.nfg_strategies.EpsilonTFT¶
- class EpsilonTFT(p, epsilon)[source]¶
Bases:
AbstractNFGStrategyA TFT player with randomized first action and probability of making mistakes.
This player acts exactly as Tit-for-Tat (repeats the last action of the opponent), however in the first round it will cooperate with probability :param p and in the subsequent rounds it has a probability :param epsilon of making a mistake and changing its action.
- Parameters:
Methods
Return the action chosen by the strategy.
Return whether the strategy is stochastic.
Return the strategy type.
- classmethod __new__(*args, **kwargs)¶
- __init__(p, epsilon)[source]¶
A TFT player with randomized first action and probability of making mistakes.
This player acts exactly as Tit-for-Tat (repeats the last action of the opponent), however in the first round it will cooperate with probability :param p and in the subsequent rounds it has a probability :param epsilon of making a mistake and changing its action.
- get_action(self: egttools.numerical.numerical_.behaviors.NormalForm.AbstractNFGStrategy, time_step: SupportsInt | SupportsIndex, action_prev: SupportsInt | SupportsIndex) int[source]¶
Return the action chosen by the strategy.
- Parameters:
- Returns:
Action selected by the strategy.
- Return type:
See also
egttools.behaviors.NormalForm.TwoActions.Cooperator,egttools.behaviors.NormalForm.TwoActions.Defector,egttools.behaviors.NormalForm.TwoActions.Random,egttools.behaviors.NormalForm.TwoActions.TFT,egttools.behaviors.NormalForm.TwoActions.SuspiciousTFT,egttools.behaviors.NormalForm.TwoActions.GenerousTFT,egttools.behaviors.NormalForm.TwoActions.GradualTFT,egttools.behaviors.NormalForm.TwoActions.ImperfectTFT,egttools.behaviors.NormalForm.TwoActions.TFTT,egttools.behaviors.NormalForm.TwoActions.TTFT,egttools.behaviors.NormalForm.TwoActions.GRIM,egttools.behaviors.NormalForm.TwoActions.Pavlov
- is_stochastic(self: egttools.numerical.numerical_.behaviors.NormalForm.AbstractNFGStrategy) bool[source]¶
Return whether the strategy is stochastic.
- type(self: egttools.numerical.numerical_.behaviors.NormalForm.AbstractNFGStrategy) str[source]¶
Return the strategy type.
- __annotations__ = {}¶