A z-Tree Course


4: Simple 2-player Games



Matteo Ploner
Università degli Studi di Trento

A symmetric coordination game


A symmetric Coordination Game


AB
A10, 10 0, 0
B0, 010, 10
  • Consider a simple 2-player Coordination Game
    • Choosing the same action leads to a positive outcome
  • Perfectly symmetric game
    • Roles (Row/Column) are not relevant
  • 2 actions available
    • A/B

Initialize Variables


Game Grid


The choice


Compute Payoffs


Payoffs


  • We condition output upon coordination
    • Different messages to those who coordinated and those who did not!

Payoffs


  • Provide participants with full information
    • Actions of both players
    • Payoffs

The Ultimatum Game


Description of the Game


  • A well-known 2-player sequential game
    1. The first mover (Proposer) proposes a share of a pie
    2. A second mover (Responder) decides whether to accept it or not
      • When the proposal is accepted, the pie is shared as proposed
      • When the proposal is rejected, both parties earn zero

Preliminaries


The Proposer's stage


The Responder's stage


Compute Payoffs


Store Results


Compute Payoffs (alternative)


  • Alternatively, you also could first "store" results
  • RECORDS.new{
    Period=:Period;
    Group=:Group;
    Sent=:tokens_sent;
    Accept=:accept_other;
    }
  • The, retrieve them to compute payoffs
  • //retrieve values from RECORDS
    Offer=RECORDS.find(same(Group) & same(Period), Sent);
    Accept=RECORDS.find(same(Group) & same(Period), Accept);
    
    //compute payoffs
    if(Proposer==1){
    Payoff=(Endowment-Offer)*Accept;
    }else{
    Payoff=Offer*Accept;
    }
    

Display Results


Assignment 1




  • Take the Coordination Game
    • Before playing the game, players can send to the other a free-form communication
    • The other player must read it in the same screen he/she is choosing

Assignment 2


  • Take the UG game
    • Manipulate the consequences of a rejection
      • A: rejection has no monetary consequences
      • B: rejection has monetary consequences only for the proposer
      • C: rejection has monetary consequences only for the responder
  • Implement a UG with strategy method
    • Responder states A/R for each possible choice, before knowing the choice of the Proposer
    • Choice of the other
      012345678910
      Your choice
  • HInt: Use arrays!