Some questions about setting up an eyetracking experiment

PennController for IBEX Forums Support Some questions about setting up an eyetracking experiment

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #10864
    sangheekim
    Participant

    Hi Jeremy,

    I was wondering if I could get some help resolving some of the issues below!

    – The image wouldn’t show up, and when I see the Debug panel, I see an error message that says “Maximum call stack size exceeded”. I won’t be able to progress to the next trial. Here is a demo link: https://farm.pcibex.net/r/RoMQQG/
    – Could you remind me what PennController does as opposed to newTrial?
    – What would be a reasonable threshold of calibration score for conducting the Visual World Paradigm experiment from your experience?
    – I have a different script that has a component of making people click on one of four images after listening to auditory stimuli. The current setup allows the cursor to show up only above the images but not elsewhere. How do I change the script such that the cursor is visible when the participant moves it around before selection?

    In the relevant trial, there is a component I hide the mouse cursor (so that the participants can’t click on the images when they are listening to the audio):

            newFunction( ()=>{
                $("body").css({
                    width: '100vw',
                    height: '100vh',
                    cursor: 'none'
               });
            }).call()
    

    And this is where the selection element is included:

            newSelector("selection")
                .enableClicks()
                .add(getImage(images[0]), 
                     getImage(images[1]),
                     getImage(images[2]),
                     getImage(images[3]))
                .log()
                .wait()
    

    Thank you!

    Best,
    Sanghee

    #10872
    Jeremy
    Keymaster

    Hi Sanghee,

    1. I don’t see the “Maximum call stack size exceeded” message, but regarding your image issue: what should happen after you show it? Right now, you tell the script to do nothing, that is, it moves to the next trial immediately after showing the image. Maybe you want to insert a Button or a Key element and wait for it

    1-bis. Relatedly, you do not .print your Button named “webcamStart” so it’s not visible on the page, and the experiment gets stuck there, waiting for a click on an undisplayed button

    2. PennController has been deprecated since version 1.7

    3. Since new projects now ship with PennController 2.1, in which the EyeTracker element has been overhauled, it’s hard to speak from experience. However, I would say start with low-ish thresholds (say 20-30) and see if you get decent data. If not, try increasing it and see if you still pass calibration

    4. If using version 2.1, note that the call command on the Function element has been replaced with run. Then try adding this line just before the Selector element: ()=>(document.querySelector("body").style.cursor='unset')

    Best,
    Jeremy

    #10876
    sangheekim
    Participant

    Hi Jeremy,

    Thanks for your help!

    Re your response to question 4: did you mean to include just that line before the Selector element? I think I’m getting a syntax error. I replaced call() with run().

    Also, I’m trying to change this code in a way that, in the initial calibration stage, the participants get 3 chances for calibration (with threshold 60), and when they do not pass the first two calibration processes, they get a message to readjust themselves, and when they finally fail to pass the final calibration step, they get a message that they cannot participate. Then the second component I’d like to include is the between-the-trial-calibration stage, where before each trial, we check whether the score is above 50, and if not, they are directed to the initial calibration process, where they have a threshold of 50 and again given 3 chances for calibration. Similar to the initial calibration stage, when they do not pass the first two calibration processes, they get a message to readjust themselves. When they finally fail to pass the final calibration step, they get a message that they cannot participate, but this time with a confirmation code they can enter on Prolific.

    So basically I’d like to set the initial calibration stage as 60, and the intermediate ones as 50, and give 3 chances to re-calibrate. But people who fail to pass the initial calibration stage cannot participate, but those who pass the initial round of calibration process but fail to pass the threshold during the trials do get a confirmation code.

    Here is a demo link I have: https://farm.pcibex.net/r/poplCg/

    Best,
    Sanghee

    #10884
    Jeremy
    Keymaster

    Hi Sanghee,

    The project you shared in your last message does not use the same version of PennController (2.0) as the project your shared in your initial message (2.1). So since your project uses 2.0, you should use .call and not .run. Also, in 2.0 you cannot just inject a bare javascript function in a trial’s script, you have to package it as a Function element, like this: newFunction( ()=>(document.querySelector("body").style.cursor='unset') ).call()

    So all in all, your code will contain these lines:

    newFunction( ()=>(document.querySelector("body").style.cursor='unset') ).call()
    ,
    newSelector("selection")
        .enableClicks()
        // etc.

    Regarding calibration, it looks like you’re already doing what you’re describing. Maybe comment back in the calibrate lines that are currently commented out, so you give your participants one last chance before setting “Failed” to “yes”. If you want to insert the FailedCalibrationLink trial between each experimental trial, just use sepWith, eg: sepWith("FailedCalibrationLink", rshuffle("Block1_target", "Block1_filler"))

    Jeremy

    #10885
    sangheekim
    Participant

    Hi Jeremy,

    Thanks again for your response. I’ll try again with your suggestions!

    Speaking of the version for the controllers, is there a way to do version control? For example, I see the calibration processes for version 2.1 (the first code I attached) and version 2.0 (the second code I attached) are different, and I would like to have these processes consistent across experiments. Is there a way to do this? Where can I find the version number in my script? And if I want to specify the version that I’m using, how can I do that?

    Best,
    Sanghee

    #10921
    Jeremy
    Keymaster

    Hi Sanghee,

    I added a page about versioning to the documentation with instructions on how to change the version of PennController that you project uses

    Jeremy

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.