Serial Port Signals Inconsistent with "correctmessage" but consistent with "errormessage" on Stroop


Serial Port Signals Inconsistent with "correctmessage" but consistent...
Author
Message
neuromech
neuromech
New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)New Member (19 reputation)
Group: Forum Members
Posts: 2, Visits: 13
We are administering the Color Word Stroop Task with Keyboard Responding on Inquisit 6. Using the serial port, we would like to deliver a signal to our EEG system at stimulus presentation and when the participant responds correctly or incorrectly. A snippet of the signals can be found below:
//1 for congruent
<port congruent>
/ port = COM12
/ subport = data
/ items = ("00001111")
</port>

//2 for correct responses
<port correct>
/ port = COM12
/ subport = data
/ items = ("10000000")
</port>

//3 for incorrect responses
<port incorrect>
/ port = COM12
/ subport = data
/ items = ("11000000")
</port>


I've used the same signals for other tasks and port.correct always appears. However, with the Stroop Task, port.correct only shows up sometimes, even though the answer is correct. On the other hand, port.incorrect always appears when the participant responds incorrectly on the task. Here is the script that I am using to deliver these signals to our EEG system through the Stroop task:
<trial redcongruent>
/ontrialbegin = [
    values.congruency = 1;
]
/ pretrialpause = 200
/ stimulustimes = [0=redcongruent, redreminder, greenreminder, bluereminder, blackreminder,congruent]
/ correctresponse = (parameters.keyred)
/ validresponse = (parameters.keyred, parameters.keygreen, parameters.keyblue, parameters.keyblack)
/ correctmessage = true(port.correct,0)
/ errormessage = true(port.incorrect,0)
/ errormessage = true(x, 400)

/ontrialend = [
    if (trial.redcongruent.responsetext == "D"){
        values.responseCategory = "red";
    } else if (trial.redcongruent.responsetext == "F"){
        values.responseCategory = "green";
    } else if (trial.redcongruent.responsetext == "J"){
        values.responseCategory = "blue";
    } else if (trial.redcongruent.responsetext == "K"){
        values.responseCategory = "black";
    };    

    //summary data:
    
    list.responses.appenditem(trial.redcongruent.correct);
    list.responses_congruent.appenditem(trial.redcongruent.correct);

    if (trial.redcongruent.correct) {
        list.latencies.appenditem(trial.redcongruent.latency);
        list.latencies_congruent.appenditem(trial.redcongruent.latency);
    }
]
</trial>


You can see port.congruent being delivered at stimulustimes. While port.correct and port.incorrect are delivered through correctmessage and errormessage. Is there a reason why port.correct is only delivered for SOME correct responses, but not others? If so, how could I change this script so that port.correct is delivered for ALL correct responses.

Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 12K, Visits: 98K
neuromech - 3/22/2024
We are administering the Color Word Stroop Task with Keyboard Responding on Inquisit 6. Using the serial port, we would like to deliver a signal to our EEG system at stimulus presentation and when the participant responds correctly or incorrectly. A snippet of the signals can be found below:
//1 for congruent
<port congruent>
/ port = COM12
/ subport = data
/ items = ("00001111")
</port>

//2 for correct responses
<port correct>
/ port = COM12
/ subport = data
/ items = ("10000000")
</port>

//3 for incorrect responses
<port incorrect>
/ port = COM12
/ subport = data
/ items = ("11000000")
</port>


I've used the same signals for other tasks and port.correct always appears. However, with the Stroop Task, port.correct only shows up sometimes, even though the answer is correct. On the other hand, port.incorrect always appears when the participant responds incorrectly on the task. Here is the script that I am using to deliver these signals to our EEG system through the Stroop task:
<trial redcongruent>
/ontrialbegin = [
    values.congruency = 1;
]
/ pretrialpause = 200
/ stimulustimes = [0=redcongruent, redreminder, greenreminder, bluereminder, blackreminder,congruent]
/ correctresponse = (parameters.keyred)
/ validresponse = (parameters.keyred, parameters.keygreen, parameters.keyblue, parameters.keyblack)
/ correctmessage = true(port.correct,0)
/ errormessage = true(port.incorrect,0)
/ errormessage = true(x, 400)

/ontrialend = [
    if (trial.redcongruent.responsetext == "D"){
        values.responseCategory = "red";
    } else if (trial.redcongruent.responsetext == "F"){
        values.responseCategory = "green";
    } else if (trial.redcongruent.responsetext == "J"){
        values.responseCategory = "blue";
    } else if (trial.redcongruent.responsetext == "K"){
        values.responseCategory = "black";
    };    

    //summary data:
    
    list.responses.appenditem(trial.redcongruent.correct);
    list.responses_congruent.appenditem(trial.redcongruent.correct);

    if (trial.redcongruent.correct) {
        list.latencies.appenditem(trial.redcongruent.latency);
        list.latencies_congruent.appenditem(trial.redcongruent.latency);
    }
]
</trial>


You can see port.congruent being delivered at stimulustimes. While port.correct and port.incorrect are delivered through correctmessage and errormessage. Is there a reason why port.correct is only delivered for SOME correct responses, but not others? If so, how could I change this script so that port.correct is delivered for ALL correct responses.

You need to specify a sufficiently long duration for the correctmessage. 0 will not do, much too short for the port signal to reliably be sent and picked up.

Not a problem for the error port, because there's a second errormessage attribute with a sufficiently long duration (400ms).

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search