Howdy, Stranger!

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

Supported by

Presenting sets with random number of stimuli in random order

edited April 2016 in OpenSesame

Hello to all,

I need some help. I am trying to build an experiment in which 5 sets of pictures will be presented in a very fast pace (0.3 second each picture). Thing is, I want the order of the pictures to be random and the order of the sets to be random as well. In addition, the sets are to be created from 2 different categories, each set with a random number of stimuli from each category (for instance, 8 from A 10 from B, 6 from A 5 from B, etc.), although the number cannot be too small (say min 4). Does anyone have an idea how to do this?

Thanks in advanced
Amihai

Comments

  • edited 9:16PM

    Any help?

    I have done some progress and have another question: Is there a way to run less cycles than the variable levels in a loop? meaning the loop will choose randomly from the levels.
    I tried putting [a variable] in the cycles number but got an error.

  • edited April 2016

    Hi Amihai,

    Have you already solved the randomization problem?

    Is there a way to run less cycles than the variable levels in a loop?

    Yes! In the loop item there is an advanced options checkbox. If you enable it, you can set a value for a break if field. In this field, you can add variable names.

    Does this make sense?

    Eduard

    Buy Me A Coffee

  • edited 9:16PM

    Dear Eduard,

    I solved part of the randomization problem using loop functions.
    I was thinking to use the "less cycles than the variable levels in a loop" solution to randomize the number of stimuli from each category (although not an elegant solution..).
    Do you know how could I use the Break if check box to do this?

    And thanks for your help.

    Amihai

  • edited 9:16PM

    Hi Amihai,

    you could use a counter variable and break the loop (with the break_if field), once the variable has a certain value. So, if you have a loop that supposed to have 15 trials, you add an inline_script to your trial_sequence, in which you increment the variable by one (counter += 1).

    Does something like that work for you?

    Good luck,

    Eduard

    btw. sorry for the late reply!

    Buy Me A Coffee

  • edited 9:16PM

    Dear Eduard (or anyone else who can help),

    Thank you very much for your replay. I used your tip and eventually managed to find a plausible solution. Yet, now I have another problem: I need to log the pictures that were eventually presented in the loop from the total number of possible pictures. The output file does not give me this information. Is there a way to do this?

    Thanks you
    Amihai

  • edited 9:16PM

    Hi Amihai,

    All exp.variables are automatically logged by the log item, so all you have to do is to store the picture names in a few variables.

    Say you have a picture list as follows: pictures = ['1.jpg','2.jpg','3.jpg'], shuffled with random.shuffle(pictures). Now you can log them as follows:

     exp.pic1 = pictures[0]
     exp.pic2 = pictures[1]
     exp.pic3 = pictures[2]
    

    Hope this hepls.

    Cheers,

    Josh

  • edited 9:16PM

    Hi Josh,

    First of all, thank you.
    Secondly, I did not understand your answer. I am using a loop function to randomly show the pictures from a variable list with the pictures names. I have two categories of pictures so to randomly show a different proportion from each category I used the "less cycles than the variable levels in a loop" option (see above). How can I know which pictures were eventually shown?

    Amihai

  • edited 9:16PM

    Still no luck.
    doed any one have an idea how to solve this?

  • edited 9:16PM

    Hi Amihai,

    What I suggested requires the use of an inline_script item. You can place that thing somewhere in your trial sequence. I also assume that your pictures have names, right? (e.g. '1.jpg'). As soon as the picture for your trial is specified, you can log it.

    Cheers,

    Josh

  • edited 9:16PM

    Hi Josh,

    I am using the sketchpad to display the images from the loop function.
    This is the text from the sketchpad script:

    set duration "[duration]"
    set description "Displays stimuli"
    draw image center=1 file="[words]" scale=1 show_if=always x=0 y=0 z_index=0

    How can i log the image from this?

    And thank you very much for your help

    Amihai

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