Howdy, Stranger!

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

Supported by

Is the RatingScale function compatible with canvas?

Hello everyone,

I have found several resources on how to do a RatingScale by using Forms and Widgets. Thanks to that I have been able to make a code that shows what I want to do, but that is not entirely functional. I want to make 6 ordinal rating scales with 6 possible answers each one (i.e., 0%, 20%, 40%, 60%, 80%,100%) and for 6 different items. But, I want all of the 6 scales to appear horizontally on the same screen. By using forms and widgets, I have not found a way to use the whole screen (not a full-screen problem) as shown in the image below.

I already tried with margins in zero, but I see no changes. So, I wondered if making these scales by using canvas instead of Forms would be better. Is that possible?

Finally, I would like to capture the reaction time of every single click (choice):


Here you have the code I wrote so far by using Forms:



form_predic = Form (cols=[1,1,1,1,1,1], rows=[1,1,1,1], margins=(0,0,0,0))


#Creating widgets1

label_inst = Label(text=f"Estimez votre niveau de confiance pour la")

label_1= Label ("lettre 1")

label_2= Label ("lettre 2")

label_3= Label ("lettre 3")

label_4= Label ("lettre 4")

label_5= Label ("lettre 5")

label_6= Label ("lettre 6")

#Creating widgets2


scale_1 = RatingScale (var=u"prediction_1", nodes=["0%","20%","40%","60%","80%","100%"])

scale_2 = RatingScale (var=u"prediction_2", nodes=["0%","20%","40%","60%","80%","100%"])

scale_3 = RatingScale (var=u"prediction_3", nodes=["0%","20%","40%","60%","80%","100%"])

scale_4 = RatingScale (var=u"prediction_4", nodes=["0%","20%","40%","60%","80%","100%"])

scale_5 = RatingScale (var=u"prediction_5", nodes=["0%","20%","40%","60%","80%","100%"])

scale_6 = RatingScale (var=u"prediction_6", nodes=["0%","20%","40%","60%","80%","100%"])


buttonp = Button(text=u"Continuer")


form_predic.set_widget(label_inst, (0,0), colspan=6)

form_predic.set_widget(label_1, (0,1), colspan=1)

form_predic.set_widget(label_2, (1,1), colspan=1)

form_predic.set_widget(label_3, (2,1), colspan=1)

form_predic.set_widget(label_4, (3,1), colspan=1)

form_predic.set_widget(label_5, (4,1), colspan=1)

form_predic.set_widget(label_6, (5,1), colspan=1)


form_predic.set_widget(scale_1, (0,2), colspan=1)

form_predic.set_widget(scale_2, (1,2), colspan=1)

form_predic.set_widget(scale_3, (2,2), colspan=1)

form_predic.set_widget(scale_4, (3,2), colspan=1)

form_predic.set_widget(scale_5, (4,2), colspan=1)

form_predic.set_widget(scale_6, (5,2), colspan=1)


form_predic.set_widget(buttonp, (0,3), colspan=6)


button_clicked = form_predic._exec()


log.write_vars()


var.i=var.i+1




I thank you in advance for all your help. It has been not easy.

Comments

  • Hi Gio,

    have you tried to specify the dimension of the experiment on the experiment tab? Standard is 1024 x 768 which is rather small (fullscreen mode just fills the area around the here specified display dimensions with the background color instead of stretching it out). When you set here the actual dimension of your screen, you should be able to use the entire screen.

    Hope this helps,

    Eduard

    Buy Me A Coffee

  • Thank you very much Eduard,

    That was very helpful. I adjusted the screen and now I'm just trying to adjust Rating Scale size but it seems no possible.

    Now, regarding my second question (i.e., how to capture the reaction time of every single click or how to do some mouse tracking) do you have any idea? I have read to how to do mouse tracking with canvas but no when using widgets and forms and rating scales.

    Thank you in advance for any help.

    Giovanny.

  • Hi Giovanny,

    Now, regarding my second question (i.e., how to capture the reaction time of every single click or how to do some mouse tracking) do you have any idea? I have read to how to do mouse tracking with canvas but no when using widgets and forms and rating scales.

    with forms, you don't have control over individual actions on that form. You only can get the start time and the end time. If you need that kind of information, you'll need to do hacky things. For example, you could put your form in a while loop, that ends the form every time an action happens (mouseclick or whatever), process that action, and then restarts the same form, updated by that action (toggle some checkbox or whatever). Do you know what I mean? For the participants it wouldn't look different visually, but you would have more control over individual events. Not sure though whether this works with all kinds of actions (an action must be able to trigger the closing of the form). If this is no option, you probably need to avoid forms, and implement your own form with canvases, and lower level drawing of boxes and implementing mouse behavior (for that the mouse tracking plugin might be useful though). I guess if you only have a few options per page, the latter option is easier.

    Hope this helps,

    Eduard

    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