mouse click pattern repeating


Author
Message
tecnika
tecnika
Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)
Group: Forum Members
Posts: 156, Visits: 790
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena
Attachments
Easy1.png (616 views, 12.00 KB)
dots.iqx (568 views, 6.00 KB)
x.png (578 views, 2.00 KB)
pattern.png (504 views, 27.00 KB)
square.png (571 views, 665 bytes)
grid.png (617 views, 7.00 KB)
fathigh.png (598 views, 24.00 KB)
Unhealthy.png (496 views, 28.00 KB)
Healthy.png (612 views, 26.00 KB)
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: 13K, Visits: 104K
ebroggin - Friday, February 3, 2017
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena

You set the the various <picture> elements to specific items based on response in <trial grid>:

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {picture.1.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.2") {picture.1.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.3") {picture.1.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "2.1") {picture.2.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.2") {picture.2.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.3") {picture.2.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "3.1") {picture.3.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.2") {picture.3.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.3") {picture.3.3.item.1 = picture.x.item.1}]

/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You need to reverse that at the start of each "round", i.e. /onblockbegin set the various picture elements *back* to their original items.

<block verbal_experiment>
/ onblockbegin = [
    picture.1.1.item.1 = picture.square.item.1;
    picture.1.2.item.1 = picture.square.item.1;
    picture.1.3.item.1 = picture.square.item.1;
    picture.2.1.item.1 = picture.square.item.1;
    picture.2.2.item.1 = picture.square.item.1;
    picture.2.3.item.1 = picture.square.item.1;
    picture.3.1.item.1 = picture.square.item.1;
    picture.3.2.item.1 = picture.square.item.1;
    picture.3.3.item.1 = picture.square.item.1;
]
/ trials = [1 = easy; 2 = verbal; 3= grid; 4= pause]
</block>

<picture square>
/ items = ("square.png")
</picture>



tecnika
tecnika
Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)
Group: Forum Members
Posts: 156, Visits: 790
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena

You set the the various <picture> elements to specific items based on response in <trial grid>:

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {picture.1.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.2") {picture.1.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.3") {picture.1.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "2.1") {picture.2.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.2") {picture.2.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.3") {picture.2.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "3.1") {picture.3.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.2") {picture.3.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.3") {picture.3.3.item.1 = picture.x.item.1}]

/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You need to reverse that at the start of each "round", i.e. /onblockbegin set the various picture elements *back* to their original items.

<block verbal_experiment>
/ onblockbegin = [
    picture.1.1.item.1 = picture.square.item.1;
    picture.1.2.item.1 = picture.square.item.1;
    picture.1.3.item.1 = picture.square.item.1;
    picture.2.1.item.1 = picture.square.item.1;
    picture.2.2.item.1 = picture.square.item.1;
    picture.2.3.item.1 = picture.square.item.1;
    picture.3.1.item.1 = picture.square.item.1;
    picture.3.2.item.1 = picture.square.item.1;
    picture.3.3.item.1 = picture.square.item.1;
]
/ trials = [1 = easy; 2 = verbal; 3= grid; 4= pause]
</block>

<picture square>
/ items = ("square.png")
</picture>



Hello,

Many thanks for your reply,

I have done that, but from the second block (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked)...Is it possible to show just an empty grid at the beginning of each part 3. (so the participant can reproduce the pattern see in part1.)?

Thanks,

Elena


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: 13K, Visits: 104K
ebroggin - Friday, February 3, 2017
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena

You set the the various <picture> elements to specific items based on response in <trial grid>:

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {picture.1.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.2") {picture.1.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.3") {picture.1.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "2.1") {picture.2.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.2") {picture.2.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.3") {picture.2.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "3.1") {picture.3.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.2") {picture.3.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.3") {picture.3.3.item.1 = picture.x.item.1}]

/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You need to reverse that at the start of each "round", i.e. /onblockbegin set the various picture elements *back* to their original items.

<block verbal_experiment>
/ onblockbegin = [
    picture.1.1.item.1 = picture.square.item.1;
    picture.1.2.item.1 = picture.square.item.1;
    picture.1.3.item.1 = picture.square.item.1;
    picture.2.1.item.1 = picture.square.item.1;
    picture.2.2.item.1 = picture.square.item.1;
    picture.2.3.item.1 = picture.square.item.1;
    picture.3.1.item.1 = picture.square.item.1;
    picture.3.2.item.1 = picture.square.item.1;
    picture.3.3.item.1 = picture.square.item.1;
]
/ trials = [1 = easy; 2 = verbal; 3= grid; 4= pause]
</block>

<picture square>
/ items = ("square.png")
</picture>



Hello,

Many thanks for your reply,

I have done that, but from the second block (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked)...Is it possible to show just an empty grid at the beginning of each part 3. (so the participant can reproduce the pattern see in part1.)?

Thanks,

Elena


> (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked).

The problem is that you perform the logic in <trial grid> /ontrialbegin. It will thus carry over from the last instance of the trial in the previous round.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You'll want to perform the logic /ontrialend instead.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialend =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>
tecnika
tecnika
Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)
Group: Forum Members
Posts: 156, Visits: 790
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena

You set the the various <picture> elements to specific items based on response in <trial grid>:

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {picture.1.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.2") {picture.1.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.3") {picture.1.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "2.1") {picture.2.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.2") {picture.2.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.3") {picture.2.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "3.1") {picture.3.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.2") {picture.3.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.3") {picture.3.3.item.1 = picture.x.item.1}]

/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You need to reverse that at the start of each "round", i.e. /onblockbegin set the various picture elements *back* to their original items.

<block verbal_experiment>
/ onblockbegin = [
    picture.1.1.item.1 = picture.square.item.1;
    picture.1.2.item.1 = picture.square.item.1;
    picture.1.3.item.1 = picture.square.item.1;
    picture.2.1.item.1 = picture.square.item.1;
    picture.2.2.item.1 = picture.square.item.1;
    picture.2.3.item.1 = picture.square.item.1;
    picture.3.1.item.1 = picture.square.item.1;
    picture.3.2.item.1 = picture.square.item.1;
    picture.3.3.item.1 = picture.square.item.1;
]
/ trials = [1 = easy; 2 = verbal; 3= grid; 4= pause]
</block>

<picture square>
/ items = ("square.png")
</picture>



Hello,

Many thanks for your reply,

I have done that, but from the second block (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked)...Is it possible to show just an empty grid at the beginning of each part 3. (so the participant can reproduce the pattern see in part1.)?

Thanks,

Elena


> (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked).

The problem is that you perform the logic in <trial grid> /ontrialbegin. It will thus carry over from the last instance of the trial in the previous round.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You'll want to perform the logic /ontrialend instead.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialend =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

That's perfect now, thanks supreme being! A last thing: Is it possible that after the third click the grid stay there for 1 sec, so the participant can see where he/she has put the third cross?

Thank you,

Elena
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: 13K, Visits: 104K
ebroggin - Monday, February 6, 2017
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena

You set the the various <picture> elements to specific items based on response in <trial grid>:

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {picture.1.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.2") {picture.1.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.3") {picture.1.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "2.1") {picture.2.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.2") {picture.2.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.3") {picture.2.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "3.1") {picture.3.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.2") {picture.3.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.3") {picture.3.3.item.1 = picture.x.item.1}]

/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You need to reverse that at the start of each "round", i.e. /onblockbegin set the various picture elements *back* to their original items.

<block verbal_experiment>
/ onblockbegin = [
    picture.1.1.item.1 = picture.square.item.1;
    picture.1.2.item.1 = picture.square.item.1;
    picture.1.3.item.1 = picture.square.item.1;
    picture.2.1.item.1 = picture.square.item.1;
    picture.2.2.item.1 = picture.square.item.1;
    picture.2.3.item.1 = picture.square.item.1;
    picture.3.1.item.1 = picture.square.item.1;
    picture.3.2.item.1 = picture.square.item.1;
    picture.3.3.item.1 = picture.square.item.1;
]
/ trials = [1 = easy; 2 = verbal; 3= grid; 4= pause]
</block>

<picture square>
/ items = ("square.png")
</picture>



Hello,

Many thanks for your reply,

I have done that, but from the second block (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked)...Is it possible to show just an empty grid at the beginning of each part 3. (so the participant can reproduce the pattern see in part1.)?

Thanks,

Elena


> (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked).

The problem is that you perform the logic in <trial grid> /ontrialbegin. It will thus carry over from the last instance of the trial in the previous round.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You'll want to perform the logic /ontrialend instead.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialend =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

That's perfect now, thanks supreme being! A last thing: Is it possible that after the third click the grid stay there for 1 sec, so the participant can see where he/she has put the third cross?

Thank you,

Elena

> 1 sec, so the participant can see where he/she has put the third cross?

Yes. Run another <trial grid> in your <block> that displays the same stimuli as <trial grid>, but is set to accept no response ( /validresponse = (0) ) and last one second ( /trialduration = 1000 ).

tecnika
tecnika
Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)Guru (14K reputation)
Group: Forum Members
Posts: 156, Visits: 790
Dave - Monday, February 6, 2017
ebroggin - Monday, February 6, 2017
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Dave - Friday, February 3, 2017
ebroggin - Friday, February 3, 2017
Hello,

I am trying to program the following task:
  1. present a pattern of cross in a 3x3 grid --> done 
  2. presenting a decision making task --> done
  3. present a 3x3 grid where the participant will need to mouse click in the same position of the previously seen pattern ---> need to be adjusted
What happens is that the first series of trials is ok, but the trials that follow has in point 3. the old pattern clicked. How can I avoid that and have always in part three a white grid at the beginning?

Please see experiment attached. Let me know if you need further information. I have just include the file Easy1 (for the pattern of dots and the fathigh example)

Thank you very very much,

Elena

You set the the various <picture> elements to specific items based on response in <trial grid>:

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {picture.1.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.2") {picture.1.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "1.3") {picture.1.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "2.1") {picture.2.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.2") {picture.2.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "2.3") {picture.2.3.item.1 = picture.x.item.1}

else if (trial.grid.response == "3.1") {picture.3.1.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.2") {picture.3.2.item.1 = picture.x.item.1}
else if (trial.grid.response == "3.3") {picture.3.3.item.1 = picture.x.item.1}]

/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You need to reverse that at the start of each "round", i.e. /onblockbegin set the various picture elements *back* to their original items.

<block verbal_experiment>
/ onblockbegin = [
    picture.1.1.item.1 = picture.square.item.1;
    picture.1.2.item.1 = picture.square.item.1;
    picture.1.3.item.1 = picture.square.item.1;
    picture.2.1.item.1 = picture.square.item.1;
    picture.2.2.item.1 = picture.square.item.1;
    picture.2.3.item.1 = picture.square.item.1;
    picture.3.1.item.1 = picture.square.item.1;
    picture.3.2.item.1 = picture.square.item.1;
    picture.3.3.item.1 = picture.square.item.1;
]
/ trials = [1 = easy; 2 = verbal; 3= grid; 4= pause]
</block>

<picture square>
/ items = ("square.png")
</picture>



Hello,

Many thanks for your reply,

I have done that, but from the second block (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked)...Is it possible to show just an empty grid at the beginning of each part 3. (so the participant can reproduce the pattern see in part1.)?

Thanks,

Elena


> (in the part 3. when the participant should click on three squares, you can see the last cross that the participant clicked).

The problem is that you perform the logic in <trial grid> /ontrialbegin. It will thus carry over from the last instance of the trial in the previous round.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialbegin =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

You'll want to perform the logic /ontrialend instead.

<trial grid>
/ ontrialbegin = [values.cross_num += 1]
/ inputdevice = mouse
/ stimulusframes = [1=grid, 1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3]
/ validresponse = (1.1,1.2,1.3,2.1,2.2,2.3,3.1,3.2,3.3)
/ ontrialend =
     [if (trial.grid.response == "1.1") {text.1.1.item.1 = text.x.item.1}
else if (trial.grid.response == "1.2") {text.1.2.item.1 = text.x.item.1}
else if (trial.grid.response == "1.3") {text.1.3.item.1 = text.x.item.1}

else if (trial.grid.response == "2.1") {text.2.1.item.1 = text.x.item.1}
else if (trial.grid.response == "2.2") {text.2.2.item.1 = text.x.item.1}
else if (trial.grid.response == "2.3") {text.2.3.item.1 = text.x.item.1}

else if (trial.grid.response == "3.1") {text.3.1.item.1 = text.x.item.1}
else if (trial.grid.response == "3.2") {text.3.2.item.1 = text.x.item.1}
else if (trial.grid.response == "3.3") {text.3.3.item.1 = text.x.item.1}]
/ branch = [if (values.cross_num < 3) trial.grid]
</trial>

That's perfect now, thanks supreme being! A last thing: Is it possible that after the third click the grid stay there for 1 sec, so the participant can see where he/she has put the third cross?

Thank you,

Elena

> 1 sec, so the participant can see where he/she has put the third cross?

Yes. Run another <trial grid> in your <block> that displays the same stimuli as <trial grid>, but is set to accept no response ( /validresponse = (0) ) and last one second ( /trialduration = 1000 ).

Thanks!!

Elena
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search