treatment "battle-of-the-sexes.ztt"{ background{ table globals{ } table subjects{ } table summary{ } table contracts{ } table clients{ } table treatments{ } table sessionglobals{ } table participations{ } numsubjects = 2; numgroups = 1; numpracticeperiods = 0; numactualperiods = 1; exchangerate = 1; startendowment = 0; showupfee = 0; noAutoscope = FALSE; firstBoxesOnTop = FALSE; showupfeeawaytext = "You are making losses. Do you want to invest the showupfee in order to continue?"; showupfeeawayyestext = "Yes"; showupfeeawaynotext = "No"; moneyawaytext = "You are making losses. Do you want to continue?"; moneyawayyestext = "Yes"; moneyawaynotext = "No"; bancruptwaittext = "Please wait until the experimenter unlocks your PC."; screen action{ usesbg = TRUE; withalertscreen = FALSE; noalertscreen = FALSE; headerbox "Header"{ hasframe = TRUE; height = 10%; top = 0p; cuttop = TRUE; showPeriods = TRUE; showNumPeriods = TRUE; periodtext = "Period"; periodoftext = "of"; practiceperiodprefix = "Trial "; showtime = TRUE; timestr = "Remaining time [sec]:"; pleasedecidetext = "Please reach a decision."; } } screen wait{ usesbg = TRUE; withalertscreen = FALSE; noalertscreen = FALSE; standardbox "Text"{ hasframe = TRUE; buttonposition = BOTTOMRIGHT; buttonsequence = HORIZONTAL; item{ label = "Please wait until the experiment continues."; } } } } stage "Decision"{ startwaitforall = TRUE; startConditionStr = ""; singleentry = FALSE; singleentrycontinuation = FALSE; timeouttype = ifnoinput; timeout = 60; program{ table = subjects; do{ // PiXY: my payoff if I choose X and the other Y (1 is A, 2 is B). Player 1 prefers A, player 2 B. Pi11 = if(Player == 1, 300, 200); Pi12 = if(Player == 1, 100, 0); Pi21 = if(Player == 1, 0, 100); Pi22 = if(Player == 1, 200, 300); } } screen action{ usesbg = TRUE; withalertscreen = FALSE; noalertscreen = FALSE; standardbox "Decision"{ hasframe = TRUE; buttonposition = BOTTOMRIGHT; buttonsequence = HORIZONTAL; item{ label = "You are player"; variable = Player; format = "1"; input = FALSE; } item{ label = "You and the other player each choose A or B. Your payoffs:"; } item{ label = "You choose A, the other A"; variable = Pi11; format = "1"; input = FALSE; } item{ label = "You choose A, the other B"; variable = Pi12; format = "1"; input = FALSE; } item{ label = "You choose B, the other A"; variable = Pi21; format = "1"; input = FALSE; } item{ label = "You choose B, the other B"; variable = Pi22; format = "1"; input = FALSE; } item{ } item{ label = "You choose"; variable = Choice; format = "!radio: 1=\"A\"; 2=\"B\";"; input = TRUE; showdefault = FALSE; emptyallowed = FALSE; min = 1; max = 2; } button "OK"{ clearinputafterok = FALSE; norecordmadeorselected = FALSE; terminatestage = FALSE; donotterminatestage = FALSE; specialbuttoncolor = FALSE; buttoncolor = 0; } } } screen wait{ usesbg = TRUE; withalertscreen = FALSE; noalertscreen = FALSE; } } stage "Results"{ startwaitforall = TRUE; startConditionStr = ""; singleentry = FALSE; singleentrycontinuation = FALSE; timeouttype = ifnoinput; timeout = 30; program{ table = subjects; do{ OtherChoice = find(same(Group) & not(same(Subject)), Choice); Profit = if(Choice == 1, if(OtherChoice == 1, Pi11, Pi12), if(OtherChoice == 1, Pi21, Pi22)); } } screen action{ usesbg = TRUE; withalertscreen = FALSE; noalertscreen = FALSE; standardbox "Results"{ hasframe = TRUE; buttonposition = BOTTOMRIGHT; buttonsequence = HORIZONTAL; item{ label = "You chose"; variable = Choice; format = "!text: 1=\"A\"; 2=\"B\";"; input = FALSE; } item{ label = "The other player chose"; variable = OtherChoice; format = "!text: 1=\"A\"; 2=\"B\";"; input = FALSE; } item{ label = "Your payoff"; variable = Profit; format = "1"; input = FALSE; } button "Continue"{ clearinputafterok = FALSE; norecordmadeorselected = FALSE; terminatestage = FALSE; donotterminatestage = FALSE; specialbuttoncolor = FALSE; buttoncolor = 0; } } } screen wait{ usesbg = TRUE; withalertscreen = FALSE; noalertscreen = FALSE; } } roles{ role "S 1"{ } role "S 2"{ } } period "1"{ prompt = ""; subject 1{ name = ""; group = 1; do{ Player = 1; } } subject 2{ name = ""; group = 1; do{ Player = 2; } } } }