Advertisement
Guest User

Untitled

a guest
Apr 5th, 2013
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.97 KB | None | 0 0
  1. # Generated by OpenSesame 0.27.2~pre4 (Frisky Freud)
  2. # Fri Apr 5 17:43:38 2013 (posix)
  3. # <http://www.cogsci.nl/opensesame>
  4.  
  5. set foreground "white"
  6. set subject_parity "even"
  7. set description "Default description"
  8. set title "New experiment"
  9. set sampler_backend "legacy"
  10. set coordinates "relative"
  11. set height "768"
  12. set mouse_backend "xpyriment"
  13. set width "1024"
  14. set compensation "0"
  15. set keyboard_backend "legacy"
  16. set background "black"
  17. set subject_nr "0"
  18. set canvas_backend "xpyriment"
  19. set start "experiment"
  20. set synth_backend "legacy"
  21.  
  22. define inline_script inline_script
  23. ___run__
  24. from libopensesame import widgets
  25. from random import shuffle
  26.  
  27. # Create a list of row indices for the questions (1, 2, and 3)
  28. # and shuffle the list. When specifying the rows for the
  29. # questions, you can then use rows[0], rows[1], and rows[2], to
  30. # get a randomized order.
  31. rows = [1,2,3]
  32. shuffle(rows)
  33.  
  34. form = widgets.form(self.experiment, cols=[1,2,1], rows=[1,1,1,1,1])
  35. title = widgets.label(form, text='Indicate how much you agree with the following statement')
  36. question1 = widgets.label(form, text='q1', center=False)
  37. question2 = widgets.label(form, text='q2', center=False)
  38. question3 = widgets.label(form, text='q3', center=False)
  39. ratingScale1 = widgets.rating_scale(form, var='question1', nodes=['Agree', "Don't know", 'Disagree'])
  40. ratingScale2 = widgets.rating_scale(form, var='question3', nodes=['Agree', "Don't know", 'Disagree'])
  41. ratingScale3 = widgets.rating_scale(form, var='question3', nodes=['Agree', "Don't know", 'Disagree'])
  42.  
  43. form.set_widget(title, (0,0), colspan=2)
  44. form.set_widget(question1, (0,rows[0]))
  45. form.set_widget(question2, (0,rows[1]))
  46. form.set_widget(question3, (0,rows[2]))
  47. form.set_widget(ratingScale1, (1,rows[0]))
  48. form.set_widget(ratingScale2, (1,rows[1]))
  49. form.set_widget(ratingScale3, (1,rows[2]))
  50. form._exec()
  51. __end__
  52. set _prepare ""
  53. set description "Executes Python code"
  54.  
  55. define sequence experiment
  56. run inline_script "always"
  57.  
  58. define form_base form_base
  59.  
  60.  
  61. define notepad getting_started
  62. __note__
  63. Hi,
  64.  
  65. Welcome to OpenSesame 0.27 "Frisky Freud"!
  66.  
  67. If you are new to OpenSesame, you may wish to follow the tutorial,
  68. which can be found online.
  69.  
  70. There are also many example experiments, which may help you to get
  71. started with creating your own. These can be found in the "examples"
  72. folder provided with OpenSesame or, again, online,
  73.  
  74. For more information, please refer to OpenSesame documentation area:
  75. <http://osdoc.cogsci.nl/>
  76.  
  77. And feel free to ask for help on the forum:
  78. <http://forum.cogsci.nl/>
  79.  
  80. Have fun with OpenSesame!
  81.  
  82. --
  83.  
  84. Sebastiaan
  85. __end__
  86. set description "Some pointers to help you get started!"
  87.  
  88. define sketchpad welcome
  89. set duration "keypress"
  90. set start_response_interval "no"
  91. set description "Displays stimuli"
  92. draw textline 0 0 "OpenSesame 0.27 'Frisky Freud'" center=1 color=white font_family="serif" font_size=32 font_italic=no font_bold=no show_if="always"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement