from otree.api import * c = cu doc = '' class C(BaseConstants): NAME_IN_URL = 'my_survey' PLAYERS_PER_GROUP = None NUM_ROUNDS = 1 class Subsession(BaseSubsession): pass class Group(BaseGroup): pass class Player(BasePlayer): my_gender = models.IntegerField(blank=True, choices=[[1, 'Female'], [2, 'Male'], [3, 'Non-binary'], [4, 'Decline to answer']], label='What is your gender?', widget=widgets.RadioSelect) my_trust = models.IntegerField(choices=[[1, '1 Most people can be trusted'], [2, '2'], [3, '3'], [4, '4'], [5, "5 You can't be too careful dealing with most people"], [6, 'Prefer not to answer']], initial=0, label='Where would you place yourself on the following scale of trust?') my_vote = models.IntegerField(blank=True, choices=[[1, 'Voting is a responsibility. People should be informed and they should vote'], [2, 'Voting is important, but I can understand why some people choose not to vote'], [3, "Whether someone votes is entirely up to them. There's nothing wrong with someone who doesn't vote"], [4, 'Prefer not to answer']], label='Which statement is closest to your own view about voting?') my_civic = models.IntegerField(blank=True, choices=[[1, '5 or more days'], [2, '3-4 days'], [3, '2-3 days'], [4, '0-1 days'], [5, 'Prefer not to answer']], label='In an average week, about how often are you involved with the community (e.g., teams, clubs, leagues, choir, student orgs, fraternities/sororities, church, meetings, etc.)?') my_social = models.IntegerField(blank=True, choices=[[1, 'Almost constantly'], [2, 'Many times a day'], [3, 'A few times a day'], [4, 'Never or almost never'], [5, 'Prefer not to answer']], label='In an average day, about how often do you use social media (e.g., TikTok, Instagram, Twitter, Facebook etc.)?') class Survey(Page): form_model = 'player' form_fields = ['my_gender', 'my_trust', 'my_vote', 'my_civic', 'my_social'] page_sequence = [Survey]