pchen

Forum Replies Created

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • in reply to: limit of results files #6743
    pchen
    Participant

    That’s good to know. Thank you!

    Peiyao

    in reply to: moving to the new farm – preload issue #6616
    pchen
    Participant

    Hi Jeremy,

    Thank you for your quick reply. I totally forgot about the CORS settings. It works again now.

    When I tested the experiment under Incognito mode, it worked great. But when I tested under non-incognito mode, it sometimes still had the loading problem until I cleared the cache. Do you have any explanations for this? I’m just curious.

    Thanks again,
    Peiyao

    in reply to: hide cursor and select by pointing #6519
    pchen
    Participant

    I went back to 1.8 and everything is working now.
    Thank you!

    in reply to: hide cursor and select by pointing #6516
    pchen
    Participant

    Hi Jeremy,

    Due to the recent upgrade (to 1.9), one function you wrote for my project doesn’t work anymore (see below). The original goal was to make a canvas disappear when the mouse moves to any of the four objects on that canvas (this thread has more details).
    Is there a way I can access the older version of PennController? If not, could you help modify the following code? Thank you!

    newFunction( ()=>new Promise(r=>$(".PennController-left-container, .PennController-right-container, .PennController-top-container, .PennController-bottom-container").bind('mouseenter',
            function(e) { getVar("choice").set( this.className.replace(/^.*(right|top|bottom|left).*$/,"$1") )._runPromises().then(r); }
        )) ).call()
    

    Peiyao

    in reply to: log the only final status of the radio button #6343
    pchen
    Participant

    That works! Thanks!

    in reply to: log global vs. local variable #6289
    pchen
    Participant

    It worked perfectly. Thank you so much!

    in reply to: presenting Chinese characters #6051
    pchen
    Participant

    It worked! Thanks!

    in reply to: hide cursor and select by pointing #6035
    pchen
    Participant

    It works now! Thank you!

    Peiyao

    in reply to: hide cursor and select by pointing #6032
    pchen
    Participant

    Hi Jeremy,

    I added “-container” to each element but still have the same issue. The var(“choice”) can’t log the actual response after a few trials.
    The undefined problem has been resolved.

    Peiyao

    in reply to: hide cursor and select by pointing #6029
    pchen
    Participant

    Hi Jeremy,

    I modified your code to add two more color patches on the top and the bottom. Specifically, the changes included creating four images (named left, right, top, and bottom), putting them on a canvas and adding top and bottom to your original code (see below). When I tried to log the var(“choice”), it showed up “undefined” in the result while other results were recorded correctly.

     newFunction( ()=>new Promise(r=>$(".PennController-left, .PennController-right, .PennController-top, .PennController-bottom").bind('mouseenter',
            e=>getVar("choice").set( e.target.className.replace(/^.*(left|right|top|bottom).*$/,"$1") )._runPromises().then(r)
        )) ).call()

    I also added a feedback screen, and sometimes the error feedback shows up even though I choose the correct response. This usually happens after a few trials.
    To test the script, I changed the correct answer to always be the top one (see below), but I still got error feedback sometimes when I only chose the top patch. This also usually only happens after a few trials.
    Is there something wrong with my modification? Here is the link to my experiment in case you want to take a look. Thank you!

      getVar("choice").test.is("top")
           .failure(getTooltip("wrong").print("center at 50vw" , "center at 50vh").wait(),
                   newTimer(1000).start().wait())
           .success(newTimer(500).start().wait())
        
         )
    in reply to: hide cursor and select by pointing #6026
    pchen
    Participant

    Hi Jeremy,

    Yes. I did have a big canvas element. It worked now. Thank you so much for your help!

    Peiyao

    in reply to: hide cursor and select by pointing #6021
    pchen
    Participant

    Hi Jeremy,

    Thank you so much for your response. The script worked well for the study.
    I do have two followup questions:

    1) what does the timeout of 1000 ms do exactly? I tried to change its duration, but nothing noticeable happened. However, there were a few times when I first moved the mouse, the trial didn’t end. The trial only ended when I moved the mouse again to a different location. Does this has anything to do with the timeout?

    2) Where should I add the feedback on a trial? When I added a tooltip after your second function, the tooltip itself appeared on the screen, but for some reason I can’t click on it and thus can’t move onto the next trial.

    Let me know if you’d like more information.

    Thanks,
    Peiyao

    in reply to: upload recording trial by trial #5885
    pchen
    Participant

    It worked! Thank you so much!

Viewing 13 posts - 1 through 13 (of 13 total)