from otree.api import * doc = """ Your app description """ class Constants(BaseConstants): name_in_url = 'demographics' players_per_group = None num_rounds = 1 class Subsession(BaseSubsession): pass class Group(BaseGroup): pass class Player(BasePlayer): q1 = models.StringField(label="What is your gender?", choices=["Male", "Female", "Other", "Prefer Not to Say"], widget=widgets.RadioSelect) q2 = models.StringField(label="What is your race?", choices=["White", "Black or African American", "Asian", "Other"], widget=widgets.RadioSelect) q3 = models.StringField(label="Are you of Hispanic or Latino origin?", choices=["Yes", "No"], widget=widgets.RadioSelect) q4 = models.StringField(label="What is your highest level of education achieved?", choices=["Some High School", "High School/GED", "Some College", "College", "Advanced Degree"], widget=widgets.RadioSelect) q5 = models.StringField(label="What is your employment status?", choices=["Student", "Unemployed", "Retired", "Full-Time Employed", "Part-Time Employed"], widget=widgets.RadioSelect) q6 = models.StringField(label="How much previous personal investment experience do you have?", choices=["No Experience", "Some Experience", "Extensive Experience"], widget=widgets.RadioSelect) q7 = models.StringField(label="How much knowledge do you have about computer programming or algorithm design?", choices=["No Knowledge", "Some Knowledge", "Extensive Knowledge"], widget=widgets.RadioSelect) # PAGES class Page1(Page): form_model = 'player' form_fields = ['q1', 'q2', 'q3', 'q4', 'q5', 'q6', 'q7'] page_sequence = [ Page1, ]