Howdy, Stranger!

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

Supported by

still randomizing the position of images

Hello.

I have found different ways proposed in the forum but I still can't find the solution. The problem is probably quite simple, sorry.

In a test we are administering a series of musical excerpts grouped in four emotional categories. The subject is asked to choose the category/emotion selecting one of the four faces in a sketchpad (afraid, happy, neutral, sad):

set duration 0
set description "Displays stimuli"
draw image center=1 file="[face_nr]AF.tif" scale=0.5 show_if=always x=-384 y=0 z_index=0
draw image center=1 file="[face_nr]HA.tif" scale=0.5 show_if=always x=-128 y=0 z_index=0
draw image center=1 file="[face_nr]NE.tif" scale=0.5 show_if=always x=128 y=0 z_index=0
draw image center=1 file="[face_nr]SA.tif" scale=0.5 show_if=always x=384 y=0 z_index=0

Through the f1, f2, f3, f4 the subject can choose the related face/emotion.

Now I have the necessity

1) to present the [face_nr]EMOTION.tif in a random order from left to right and

2) to log the correct response.

But unfortunately I can't find a solution.

Could you suggest me a way to do that ?

Thank you very much for your attention

Comments

  • Hi,


    1) to present the [face_nr]EMOTION.tif in a random order from left to right and

    This you can achieve but not only code the emotion as a variable in your experiment, but also the position. In the easiest way, you can completetly counterbalance it in the loop table (see for example the beginner's tutorial where this is also done).If this is not feasible for whatever reason, you can randomly assign the positions in an inline_script (prepare phase) before the sketchpad. Something like this will do:

    import random
    position_x = [-300, -100, 100, 300 ]
    random.shuffle(position_x)
    var.x1, var.x2, var.x3, var.x3 = position_x
    

    Then you can also change the value in your screenshot to [x1], [x2], [x3], [x4] as x coordinate.

    2) to log the correct response.

    You must link the location of the emotion to the location of the correct response. For this you need to know where each emotion was placed. With the code above, I don't think you have control over the location. It might make more sense, to not shuffle the x positions, but shuffle the image identity. Same principle:

    import random
    face_id = ['[face_nr]NE.tif','[face_nr]AF.tif','[face_nr]HA.tif','[face_nr]SA.tif' ]
    random.shuffle(face_id)
    var.face1, var.face2, var.face3, var.face4 = face_id
    

    Now you only need to collect the response (1, 2, 3, or 4) and check which emotion was coded at that position (coded in var.faceX). If this label matches the predefined condition, you have a correct response and an incorrect response otherwise.

    Eduard

    Buy Me A Coffee

  • Dear Eduard,

    it was a bit harder than expected but we did it, thank you very much !

  • Good to hear!

    Buy Me A Coffee

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