Shared Scripts, Data, Stimuli, Files, and Demos
If you are a registered user and signed in, you can here copy this script and its stimuli to your own account, where you can edit it and change it in any way you want.
It is absolutely free to register (no credit card info asked!). You can then instantly copy this experiment with one click and edit it, change its accompanying texts, its landing page, stimuli, etc. Invite your colleagues, friends, or students to check out your experiment. There is no limit on how many people can do your experiment, even with a free account.
The catch? There is no catch! Just keep in mind that with a free account, you cannot collect data. For teaching that is usually not a problem. For research, prepaid data collection (unlimited subjects) starts as low as €10.00 for a 10-day period.
instruction('First you will be asked about some demographics, and hereafter there will be a short questionnaire before the experiment starts'); var a1,a2,a3, a4, b1; //a1=age, a2=gender, a3=button, b1=header a4=device b1 = main.addblock(0,0,100,40); a1 = main.addblock(40,30,20,20); a2 = main.addblock(35,45,20,20); a3 = main.addblock("center",80,30,20); a4 = main.addblock("center",60,100,20); main.setfontsize(70); //Demographics b1.text("Demographics
Please provide some basic information about yourself before starting the experiment.
"); startform(); a1.input("Your age","Age"); a2.select("Your gender",[['Male',0],['Female',1],['Other',2],['Prefer not to say',3]],"Gender"); a4.select("What device are you responding from",[['Tablet or phone or laptop with touchscreen',1],['Laptop with keyboard/mouse',2]],"device_type"); a3.button("Continue","inputbutton","click","inputbutton").await('click'); endform(); b1.clear(); a3.clear(); a1.destroy(); a2.destroy(); a4.destroy(); var header, q1, q2, q3, q4, q5, q6, q7, button2, button3, button4; header = main.addblock(0,0,100,1).style("font-size","70%"); q1 = main.addblock(0,10,30,30); q2 = main.addblock(0,35,30,30); q3 = main.addblock(0,60,30,30); button2 = main.addblock("center",80,30,20); main.setfontsize(60); header.text("Questionnaire
Please read each statement and indicate how much the statement applied to you over the past week. There are no right or wrong answers. Do not spend too much time on any statement"); startform(); q1.select("I was aware of dryness of my mouth",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question1"); q2.select("I experienced breathing difficulty (e.g. excessively rapid breathing,breathlessness in the absence of physical exertion)",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question2"); q3.select("I experienced trembling (e.g. in the hands)",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question3"); button2.button("Continue","inputbutton","click","inputbutton").await('click'); endform(); button2.clear(); q1.destroy(); q2.destroy(); q3.destroy(); q4 = main.addblock(0,30,20,20); q5 = main.addblock(0,60,20,20); button3 = main.addblock("center",80,30,20); startform(); q4.select("I was worried about situations in which I might panic and make a fool of myself",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question4"); q5.select("I felt I was close to panic",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question5"); button3.button("Continue","inputbutton","click","inputbutton").await('click'); endform(); button3.clear(); q4.destroy(); q5.destroy(); q6 = main.addblock(0,30,20,20); q7 = main.addblock(0,50,30,30); button4 = main.addblock("center",80,30,20); startform(); q6.select("I was aware of the action of my heart in the absence of physical exertion (e.g. sense of heart rate increase, heart missing a beat) ",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question6"); q7.select("I felt scared without any good reason ",[['Did not apply to me at all',0],['Applied to me to some degree, or some of the time',1],['Applied to me to a considerable degree or a good part of time',2],['Applied to me very much or most of the time',3]],"question7"); button4.button("Continue","inputbutton","click","inputbutton").await('click'); endform(); header.clear(); button4.clear(); q6.destroy(); q7.destroy(); dass_total = parseFloat(response.question1) + parseFloat(response.question2) + parseFloat(response.question3) + parseFloat(response.question4) + parseFloat(response.question5) + parseFloat(response.question6) + parseFloat(response.question7); log(dass_total,"dass_calc_total"); var i, t, e, fixation = '+', stimuli = ["😠😠😠😠😠","🙂🙂🙂🙂🙂","🙂🙂😠🙂🙂","😠😠🙂😠😠"], //< is upsidedown, > is happy // The following is a simple way to do counter-balancing: trials = shuffle([0,0,0,0,0,1,1,1,1,1,2,2,2,2,2,3,3,3,3,3]), correct_congruent = 0, correct_incongruent = 0; rt_correct_congruent = 0, rt_correct_incongruent = 0, rtcc_happy = [], rtci_happy = [], rtcc_angry = [], rtci_angry = [], // arrays to save RTs left = addblock(30,90,10,7,"lightgrey","<","left"), right = addblock(60,90,10,7,"lightgrey",">","right"); main.setfontsize(60); // Makes the base font size a bit smaller: 60% instruction('Watch the middle character of the five characters presented.
' + 'If it is a 😠 tap on the "< Button". ' + 'You may also click the button with the mouse or press the Left Arrow Key on the keyboard.
' + 'If it is a 🙂, tap or click the "> Button", or press the Right Arrow Key.
'); instruction('The middle character is surrounded by similar characters, which you must ignore.
' + 'When you see 🙂🙂😠🙂🙂 or 😠😠😠😠😠 tap the "< Button" (or <- Arrow Key).
' + 'With 😠😠🙂😠😠 or 🙂🙂🙂🙂🙂 click the "> Button" (or -> Arrow Key).
' + 'Please, try to respond as fast as possible (within 2 seconds)
'); instruction('Basically, only focus on the middle emoji and try to ignore the surrounding emojis.
' + 'If the middle emoji is 🙂 press >
' + 'If the middle emoji is 😠 press <
' + 'Again, please, try to respond as fast as possible (within 2 seconds)!
' + ' The experiment starts when you press OK'); text("Get ready!"); await(1000); for (i = 0; i < trials.length; i++) { clear(); await(1000); t = trials[i]; text(stimuli[t],300); waitfor { // TODO: replace by await_or e = await('click',2000); // Wait for either a mouse click on the button... } or { e = awaitkey('LEFT_ARROW,RIGHT_ARROW'); // ... or a keyboard key: <- or -> } if (e.type === 'timeout') { logtrial('timeout'); alert("You were too slow. Please, try to click or tap faster"); continue; } if (!e.event.target.id || e.event.target.id === 'undefined') { alert("Please, click or tap on the < or > buttons"); continue; } if ((e.key && e.key === keys.LEFT_ARROW) || (e.event.target.id && e.event.target.id === 'left')) { if (t === 0) { ++correct_congruent; rt_correct_congruent += e.RT; rtcc_angry.push(e.RT); logtrial(e.RT,"RT", "rtcc_angry"); } else if (t === 2) { ++correct_incongruent; rt_correct_incongruent += e.RT; rtci_angry.push(e.RT); logtrial(e.RT,"RT", "rtci_angry"); } } else if ((e.key && e.key === keys.RIGHT_ARROW) || (e.event.target.id && e.event.target.id === 'right')) { if (t === 1) { ++correct_congruent; rt_correct_congruent += e.RT; rtcc_happy.push(e.RT); logtrial(e.RT,"RT", "rtcc_happy"); } else if (t === 3) { ++correct_incongruent; rt_correct_incongruent += e.RT; rtci_happy.push(e.RT); logtrial(e.RT,"RT", "rtci_happy"); } } } endscreen = main.addblock(0,0,100,100); endscreen.style("background-color", "white"); endscreen.text("That was all. Thank you very much for your participation!"); endscreen.await(2500);
Data inspection is forthcoming!
In the mean time, authors may download their own data and make it available as an Excel file. Check out the 'Stimuli and Files' tab.
Click on a category to view the stimuli and files
You can download the files shown here by clicking on the file names or image. Note that you cannot link directly to the images, sounds, videos, etc. shown here from other web pages; the link will go stale in about one hour and will no longer work after that.
This experiment has no imagesYou can download the files shown here by clicking on the file names or image. Note that you cannot link directly to the images, sounds, videos, etc. shown here from other web pages; the link will go stale in about one hour and will no longer work after that.
This experiment has no imagesYou can download the files shown here by clicking on the file names or image. Note that you cannot link directly to the images, sounds, videos, etc. shown here from other web pages; the link will go stale in about one hour and will no longer work after that.
This experiment has no imagesYou can download the files shown here by clicking on the file names or image. Note that you cannot link directly to the images, sounds, videos, etc. shown here from other web pages; the link will go stale in about one hour and will no longer work after that.
This experiment has no images