from otree.api import ( models, widgets, BaseConstants, BaseSubsession, BaseGroup, BasePlayer, Currency as c, currency_range, ) author = 'Maren and Mounir' doc = """ This app is for the portfolio selection part of the experiment """ class Constants(BaseConstants): name_in_url = 'pf_select' players_per_group = None num_rounds = 1 team_utilities=[314, 294, 276] class Subsession(BaseSubsession): pass class Group(BaseGroup): pass class Player(BasePlayer): # Here is the formfield that saves the player's decision about the selected team choice_selectPortfolio=models.IntegerField( label="Please choose your preferred team to hire: (e.g. 1)", min=1, max=3 ) # Here is the formfield that saves the player's perceived complexity complex_selectPortfolio=models.FloatField( label="I would rate the complexity/difficulty of this task as (0% simple – 100% difficult). Type your answer without the percentage sign:", min=0, max=100 ) # Here is the variable that saves the achieved utility of a player's chosen team u_selectPortfolio=models.FloatField( initial=0 ) # Here are the variables for tracking the changes of the player's decision in the portfolio selection part current_team = models.IntegerField() all_teams = models.StringField()