Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

Impossible to Constrain loop

Hi all,

I am creating a “quiz” about fictional profiles in my experiment.  I would like to constrain the number of questions displayed per profile, but I can’t manage to do so. I would really appreciate if some could help me.

In my experiment, I have 6 fictional male profiles (man A; man B, man C, man D, man D, man F) and 6 fictional female profiles (woman A, …, woman F).

At one point, I want to display, one at a time, each profile picture with either a true or a false statement (placed underneath the picture). Then the participant has to respond by either true or false to the statement (by pressing p for a true statement or by pressing e for a wrong statement).  

However, I would like to display only one of the two statements per profile not the two (for example, if the first statement to be displayed for man A is the true one, I don’t want the false statement of man A to be displayed in a following later. The same is applicable if the first statement is the false one, I don’t want the true one to be displayed later).

So, I have created such a “quiz” (using loop, sequence, sketchpad, keyboard response, logger) that seem to work. In my loop, I have created 4 variables: gender (man, woman); id (a, b, c, d, e, f); statement (true, false); correct response (p, e). Please see the attached picture for a screenshot of the loop.  

The problem is that I always end up with 24 trials, with the two statements being displayed per profile (once at a time, and in a random order) but I only want one of the two statements (so 12 trials in total).


In the script, I tried to use the following command:  constrain id maxrep=1, but the command seems to be ignored.

I tried different other things but nothing works, I always have 24 trials in my loop.

It would be really much appreciated if someone could help me with it. 

Comments

  • Hi @bbTokyobb,

    To achieve what you would like, I'd say you have two options:

    Option 1

    Instead of having all profiles and statements in one loop, you could use nested loops, whereby when a row from the upper loop (profile) is running, you define the statement from a lower-level loop that contains only two statements and set the repeat property of that loop to 0.5 and its order to random. That way, for each profile, only one statement would be picked at random. Depending on how your trials are organized (I don't know whether you're using the same two statements for all profiles, if you have different pairs of statements for each profile, if these are fixed or randomly allocated to profiles), you might have to introduce a little programming or use the "run if" property to select the appropriate lower-level loop for each profile.

    Option 2

    You could use the loop as you have it now and use some programming to keep track of how many statements have been shown for each profile. You could then use that variable to program the "run if" property of the loop to determine what objects have to be executed when the trial runs. This methods will execute 24 trials but if you program it all correctly, 12 of these will be dummy trials (you can make it so that nothing is presented and subjects will not notice anything before the next actual trial is presented). So, with this method, your data log will contain trials in which many variables will be empty.

    The maxrep constrain does not achieve what you want because this variable only allows you to prevent the repetition of a same variable value in two successive trials.

    Hope this helps!

    Fabrice.

    Buy Me A Coffee

  • Hello Fabrice,


    Thank you so much for your reply.

    I followed your Option 1 and I used a nested loop in which I put the statementz and the correct response inside a bigger loop in which I put the profiles only. Then I set the repeat property of the nested loop to 0.5 and it works perfectly. I have my desired 12 trials.

    Thanks a lot for your help!


    (To clarify, I have different pairs of fixed statements allocated per profiles)

Sign In or Register to comment.

agen judi bola , sportbook, casino, togel, number game, singapore, tangkas, basket, slot, poker, dominoqq, agen bola. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 50.000 ,- bonus cashback hingga 10% , diskon togel hingga 66% bisa bermain di android dan IOS kapanpun dan dimana pun. poker , bandarq , aduq, domino qq , dominobet. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 10.000 ,- bonus turnover 0.5% dan bonus referral 20%. Bonus - bonus yang dihadirkan bisa terbilang cukup tinggi dan memuaskan, anda hanya perlu memasang pada situs yang memberikan bursa pasaran terbaik yaitu http://45.77.173.118/ Bola168. Situs penyedia segala jenis permainan poker online kini semakin banyak ditemukan di Internet, salah satunya TahunQQ merupakan situs Agen Judi Domino66 Dan BandarQ Terpercaya yang mampu memberikan banyak provit bagi bettornya. Permainan Yang Di Sediakan Dewi365 Juga sangat banyak Dan menarik dan Peluang untuk memenangkan Taruhan Judi online ini juga sangat mudah . Mainkan Segera Taruhan Sportbook anda bersama Agen Judi Bola Bersama Dewi365 Kemenangan Anda Berapa pun akan Terbayarkan. Tersedia 9 macam permainan seru yang bisa kamu mainkan hanya di dalam 1 ID saja. Permainan seru yang tersedia seperti Poker, Domino QQ Dan juga BandarQ Online. Semuanya tersedia lengkap hanya di ABGQQ. Situs ABGQQ sangat mudah dimenangkan, kamu juga akan mendapatkan mega bonus dan setiap pemain berhak mendapatkan cashback mingguan. ABGQQ juga telah diakui sebagai Bandar Domino Online yang menjamin sistem FAIR PLAY disetiap permainan yang bisa dimainkan dengan deposit minimal hanya Rp.25.000. DEWI365 adalah Bandar Judi Bola Terpercaya & resmi dan terpercaya di indonesia. Situs judi bola ini menyediakan fasilitas bagi anda untuk dapat bermain memainkan permainan judi bola. Didalam situs ini memiliki berbagai permainan taruhan bola terlengkap seperti Sbobet, yang membuat DEWI365 menjadi situs judi bola terbaik dan terpercaya di Indonesia. Tentunya sebagai situs yang bertugas sebagai Bandar Poker Online pastinya akan berusaha untuk menjaga semua informasi dan keamanan yang terdapat di POKERQQ13. Kotakqq adalah situs Judi Poker Online Terpercayayang menyediakan 9 jenis permainan sakong online, dominoqq, domino99, bandarq, bandar ceme, aduq, poker online, bandar poker, balak66, perang baccarat, dan capsa susun. Dengan minimal deposit withdraw 15.000 Anda sudah bisa memainkan semua permaina pkv games di situs kami. Jackpot besar,Win rate tinggi, Fair play, PKV Games