Millisecond Forums

Customizing Color Shape task

https://forums.millisecond.com/Topic21008.aspx

By BobRamakers - 3/7/2017

Dear all,

I would like to use a customized version of the Color Shape task of Miyake et al in an experiment.
Can someone advise how to make the following adjustments in this test?

Currently the test consists of multiple situations:

1. Blocked shape training
2. Blocked color training
3. Blocked color-shape training
4. Blocked bivalent shape training
5. Blocked bivalent color training
6. Blocked bivalent shape TEST
7. Blocked bivalent color TEST
8. Mixed word training
9. Mixed letter training
10. Mixed word TEST
11. Mixed letterTEST

First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

I look forward to hearing from you.

Best regards,

Bob Ramakers
By Dave - 3/8/2017

BobRamakers - Wednesday, March 8, 2017
Dear all,

I would like to use a customized version of the Color Shape task of Miyake et al in an experiment.
Can someone advise how to make the following adjustments in this test?

Currently the test consists of multiple situations:

1. Blocked shape training
2. Blocked color training
3. Blocked color-shape training
4. Blocked bivalent shape training
5. Blocked bivalent color training
6. Blocked bivalent shape TEST
7. Blocked bivalent color TEST
8. Mixed word training
9. Mixed letter training
10. Mixed word TEST
11. Mixed letterTEST

First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

I look forward to hearing from you.

Best regards,

Bob Ramakers

> First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Remove the blocks you do not wish to administer from the script's <expt> elements as detailed in the comments:

"Block Order can be edited/customized under each of the 4 expt-elements below.
Default flow:
/blocks = [
1 = generalintro;
2 = blockedintro;
3 = blockedtask_shapetraining;
4 = blockedtask_colortraining;
5 = blockedtask_colorshapetraining;
6 = blockedtask_bivalentshapetraining;
7 = blockedtask_bivalentcolortraining;
8 = blocked_testintro;
9-10 = noreplace(blocked_color, blocked_shape);
11 = mixedintro;
12-13 = noreplace(mixed_practiceword, mixed_practiceletter);
14 = mixed_testintro;
15-18 = noreplace(mixed_letter_longCSI, mixed_letter_shortCSI, mixed_word_longCSI, mixed_word_shortCSI)]

to run only the Mixed Condition (might have to edit instruction pages as well) use:
/blocks = [
1 = generalintro;
2 = mixedintro;
3-4 = noreplace(mixed_practiceword, mixed_practiceletter);
5 = mixed_testintro;
6-9 = noreplace(mixed_letter_longCSI, mixed_letter_shortCSI, mixed_word_longCSI, mixed_word_shortCSI)]"

You'll want to eliminate mixed_practiceletter, mixed_letter_longCSI and mixed_letter_shortCSI and adjust the block numbers accordingly.

> Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

First you have to spell out what you conceive "TEST situations" for 1, 2 and 3 to be. How would they differ from the training blocks? What prevents you from simply running *two* blocks each -- one "training", one "TEST"?
By BobRamakers - 3/8/2017

Dave - Wednesday, March 8, 2017
BobRamakers - Wednesday, March 8, 2017
Dear all,

I would like to use a customized version of the Color Shape task of Miyake et al in an experiment.
Can someone advise how to make the following adjustments in this test?

Currently the test consists of multiple situations:

1. Blocked shape training
2. Blocked color training
3. Blocked color-shape training
4. Blocked bivalent shape training
5. Blocked bivalent color training
6. Blocked bivalent shape TEST
7. Blocked bivalent color TEST
8. Mixed word training
9. Mixed letter training
10. Mixed word TEST
11. Mixed letterTEST

First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

I look forward to hearing from you.

Best regards,

Bob Ramakers

> First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Remove the blocks you do not wish to administer from the script's <expt> elements as detailed in the comments:

"Block Order can be edited/customized under each of the 4 expt-elements below.
Default flow:
/blocks = [
1 = generalintro;
2 = blockedintro;
3 = blockedtask_shapetraining;
4 = blockedtask_colortraining;
5 = blockedtask_colorshapetraining;
6 = blockedtask_bivalentshapetraining;
7 = blockedtask_bivalentcolortraining;
8 = blocked_testintro;
9-10 = noreplace(blocked_color, blocked_shape);
11 = mixedintro;
12-13 = noreplace(mixed_practiceword, mixed_practiceletter);
14 = mixed_testintro;
15-18 = noreplace(mixed_letter_longCSI, mixed_letter_shortCSI, mixed_word_longCSI, mixed_word_shortCSI)]

to run only the Mixed Condition (might have to edit instruction pages as well) use:
/blocks = [
1 = generalintro;
2 = mixedintro;
3-4 = noreplace(mixed_practiceword, mixed_practiceletter);
5 = mixed_testintro;
6-9 = noreplace(mixed_letter_longCSI, mixed_letter_shortCSI, mixed_word_longCSI, mixed_word_shortCSI)]"

You'll want to eliminate mixed_practiceletter, mixed_letter_longCSI and mixed_letter_shortCSI and adjust the block numbers accordingly.

> Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

First you have to spell out what you conceive "TEST situations" for 1, 2 and 3 to be. How would they differ from the training blocks? What prevents you from simply running *two* blocks each -- one "training", one "TEST"?

Dear Dave,

Thank you for your swift response.
Blocks 9-11 have been deleted, this is fine now.

I have not yet figured out how to make tests for all situations. The following is how the experiment should look like:

1. Blocked shape training
2. Blocked shape TEST
3. Blocked color training
4. Blocked color TEST
5. Blocked color-shape training
6. Blocked color-shape TEST
7. Blocked bivalent shape training
8. Blocked bivalent shape TEST
9. Blocked bivalent color training
10. Blocked bivalent color TEST
11. Mixed word training
12. Mixed word TEST

I would like to only gather data from the tests. And tests should have more trials than trainings.

It would be great if you can help me to customize the script according to this information.

Best regards,

Bob Ramakers
By Dave - 3/9/2017

BobRamakers - Thursday, March 9, 2017
Dave - Wednesday, March 8, 2017
BobRamakers - Wednesday, March 8, 2017
Dear all,

I would like to use a customized version of the Color Shape task of Miyake et al in an experiment.
Can someone advise how to make the following adjustments in this test?

Currently the test consists of multiple situations:

1. Blocked shape training
2. Blocked color training
3. Blocked color-shape training
4. Blocked bivalent shape training
5. Blocked bivalent color training
6. Blocked bivalent shape TEST
7. Blocked bivalent color TEST
8. Mixed word training
9. Mixed letter training
10. Mixed word TEST
11. Mixed letterTEST

First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

I look forward to hearing from you.

Best regards,

Bob Ramakers

> First, I would like to remove situation 9 and 11. Can someone advise on how to do this?

Remove the blocks you do not wish to administer from the script's <expt> elements as detailed in the comments:

"Block Order can be edited/customized under each of the 4 expt-elements below.
Default flow:
/blocks = [
1 = generalintro;
2 = blockedintro;
3 = blockedtask_shapetraining;
4 = blockedtask_colortraining;
5 = blockedtask_colorshapetraining;
6 = blockedtask_bivalentshapetraining;
7 = blockedtask_bivalentcolortraining;
8 = blocked_testintro;
9-10 = noreplace(blocked_color, blocked_shape);
11 = mixedintro;
12-13 = noreplace(mixed_practiceword, mixed_practiceletter);
14 = mixed_testintro;
15-18 = noreplace(mixed_letter_longCSI, mixed_letter_shortCSI, mixed_word_longCSI, mixed_word_shortCSI)]

to run only the Mixed Condition (might have to edit instruction pages as well) use:
/blocks = [
1 = generalintro;
2 = mixedintro;
3-4 = noreplace(mixed_practiceword, mixed_practiceletter);
5 = mixed_testintro;
6-9 = noreplace(mixed_letter_longCSI, mixed_letter_shortCSI, mixed_word_longCSI, mixed_word_shortCSI)]"

You'll want to eliminate mixed_practiceletter, mixed_letter_longCSI and mixed_letter_shortCSI and adjust the block numbers accordingly.

> Second, I would like to add TEST situations for 1, 2 and 3. Can someone advise on how to do this?

First you have to spell out what you conceive "TEST situations" for 1, 2 and 3 to be. How would they differ from the training blocks? What prevents you from simply running *two* blocks each -- one "training", one "TEST"?

Dear Dave,

Thank you for your swift response.
Blocks 9-11 have been deleted, this is fine now.

I have not yet figured out how to make tests for all situations. The following is how the experiment should look like:

1. Blocked shape training
2. Blocked shape TEST
3. Blocked color training
4. Blocked color TEST
5. Blocked color-shape training
6. Blocked color-shape TEST
7. Blocked bivalent shape training
8. Blocked bivalent shape TEST
9. Blocked bivalent color training
10. Blocked bivalent color TEST
11. Mixed word training
12. Mixed word TEST

I would like to only gather data from the tests. And tests should have more trials than trainings.

It would be great if you can help me to customize the script according to this information.

Best regards,

Bob Ramakers

> I would like to only gather data from the tests.

<block blockedtask_colortraining>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numberpracticetrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/ recorddata = false
</block>

> And tests should have more trials than trainings.

Make copies of the three practice blocks in the script and all associated elements. Rename the blocks and elements, indicating that they are now for  test purposes. Adjust the number of trials, etc. for these new blocks according to your needs. Run those blocks at the desired point in time via the <expt>s.
By BobRamakers - 3/13/2017

Hi Dave,

Thank you again for your response.
I did the following but now I have only another copy of the instruction slide, no new test trials.

- Copied the blocks in all 4 <expt> and renamed these (3 = noreplace(shapetest); 5 = noreplace(colortest); and 7 = noreplace(colorshapetest);)
- Copied the following in the BLOCKED TASK: TEST BLOCKS



<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colortest>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colorshapetest>
/onblockbegin = [values.selectinstruct = 3]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>



- Copied the following in BLOCKED TASK: TEST TRIALS



<trial blockedtask_shapetest>
/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

<trial blockedtask_colortest>
/ontrialbegin = [values.categorizationtask = "Kleur"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 3 else values.selectstim = 4]
/ontrialbegin = [if (values.selectstim == 3) values.color = "Rood" else values.color = "Groen"]
/ontrialbegin = [values.shape = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 3 && trial.blockedtask_colortest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colortest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


<trial blockedtask_colorshapetest>
/ontrialbegin = [values.selectstim = list.blocked_trainingB.nextvalue]
/ontrialbegin = [if (values.selectstim < 3) values.categorizationtask = "Vorm" else values.categorizationtask = "Kleur"]

/ontrialbegin = [if (values.selectstim == 1) {values.shape = "Cirkel"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 2) {values.shape = "Driehoek"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 3) {values.shape = ""; values.color = "Rood"}]
/ontrialbegin = [if (values.selectstim == 4) {values.shape = ""; values.color = "Groen"}]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle, values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_colorshapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_colorshapetest.response == values.responsekey_triangle) ||
(values.selectstim == 3 && trial.blockedtask_colorshapetest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colorshapetest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>



I thought I copied all three blocks and associated elements with this, but apparently I didn't.
Can you please advise again on how to adapt the script?

Best regards,

Bob Ramakers
By Dave - 3/13/2017

BobRamakers - Monday, March 13, 2017
Hi Dave,

Thank you again for your response.
I did the following but now I have only another copy of the instruction slide, no new test trials.

- Copied the blocks in all 4 <expt> and renamed these (3 = noreplace(shapetest); 5 = noreplace(colortest); and 7 = noreplace(colorshapetest);)
- Copied the following in the BLOCKED TASK: TEST BLOCKS



<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colortest>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colorshapetest>
/onblockbegin = [values.selectinstruct = 3]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>



- Copied the following in BLOCKED TASK: TEST TRIALS



<trial blockedtask_shapetest>
/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

<trial blockedtask_colortest>
/ontrialbegin = [values.categorizationtask = "Kleur"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 3 else values.selectstim = 4]
/ontrialbegin = [if (values.selectstim == 3) values.color = "Rood" else values.color = "Groen"]
/ontrialbegin = [values.shape = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 3 && trial.blockedtask_colortest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colortest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


<trial blockedtask_colorshapetest>
/ontrialbegin = [values.selectstim = list.blocked_trainingB.nextvalue]
/ontrialbegin = [if (values.selectstim < 3) values.categorizationtask = "Vorm" else values.categorizationtask = "Kleur"]

/ontrialbegin = [if (values.selectstim == 1) {values.shape = "Cirkel"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 2) {values.shape = "Driehoek"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 3) {values.shape = ""; values.color = "Rood"}]
/ontrialbegin = [if (values.selectstim == 4) {values.shape = ""; values.color = "Groen"}]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle, values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_colorshapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_colorshapetest.response == values.responsekey_triangle) ||
(values.selectstim == 3 && trial.blockedtask_colorshapetest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colorshapetest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>



I thought I copied all three blocks and associated elements with this, but apparently I didn't.
Can you please advise again on how to adapt the script?

Best regards,

Bob Ramakers

> I did the following but now I have only another copy of the instruction slide

The block starts with an instruction trial:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

The instruction item that trial displays is determined by

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>
.
You need to add instruction items for the test blocks and adjust the item number values.selectinstruct is set to /onblockbegin accordingly.

Further, the block then invokes <trial selecblocketraining>

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

That <trial> then invokes the training trials via /branch

<trial selectblockedtraining>
/branch = [if (script.currentblock == "blockedtask_shapetraining") trial.blockedtask_shapetraining]
/branch = [if (script.currentblock == "blockedtask_colortraining") trial.blockedtask_colortraining]
/branch = [if (script.currentblock == "blockedtask_colorshapetraining") trial.blockedtask_colorshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentshapetraining") trial.blockedtask_bivalentshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentcolortraining") trial.blockedtask_bivalentcolortraining]
/trialduration = 0
/recorddata = false
</trial>

For context, look at how the already existing test blocks function -- they do so in basically the same way:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

<block blocked_color>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

Start with an instruction trial -- <trial blockedtestinstruct> -- with the instruction item selected /onblockbegin via values.selectinstruct.

Then move to a selection trial -- <trial selectblockedtrial> -- with the requisite /branch logic

<trial selectblockedtrial>
/branch = [if (script.currentblock == "blocked_shape") trial.blockedtask_bivalentshapetest else trial.blockedtask_bivalentcolortest]
/trialduration = 0
/recorddata = false
</trial>

to invoke the proper type of trial (<trial blockedtask_bivalentshapetest> for <block blocked_shape>; <trial .blockedtask_bivalentcolortest> for <block blocked_color>).

This continues until the <block>'s /stop condition is met:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

By BobRamakers - 3/14/2017

Dave - Monday, March 13, 2017
BobRamakers - Monday, March 13, 2017
Hi Dave,

Thank you again for your response.
I did the following but now I have only another copy of the instruction slide, no new test trials.

- Copied the blocks in all 4 <expt> and renamed these (3 = noreplace(shapetest); 5 = noreplace(colortest); and 7 = noreplace(colorshapetest);)
- Copied the following in the BLOCKED TASK: TEST BLOCKS



<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colortest>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colorshapetest>
/onblockbegin = [values.selectinstruct = 3]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>



- Copied the following in BLOCKED TASK: TEST TRIALS



<trial blockedtask_shapetest>
/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

<trial blockedtask_colortest>
/ontrialbegin = [values.categorizationtask = "Kleur"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 3 else values.selectstim = 4]
/ontrialbegin = [if (values.selectstim == 3) values.color = "Rood" else values.color = "Groen"]
/ontrialbegin = [values.shape = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 3 && trial.blockedtask_colortest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colortest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


<trial blockedtask_colorshapetest>
/ontrialbegin = [values.selectstim = list.blocked_trainingB.nextvalue]
/ontrialbegin = [if (values.selectstim < 3) values.categorizationtask = "Vorm" else values.categorizationtask = "Kleur"]

/ontrialbegin = [if (values.selectstim == 1) {values.shape = "Cirkel"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 2) {values.shape = "Driehoek"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 3) {values.shape = ""; values.color = "Rood"}]
/ontrialbegin = [if (values.selectstim == 4) {values.shape = ""; values.color = "Groen"}]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle, values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_colorshapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_colorshapetest.response == values.responsekey_triangle) ||
(values.selectstim == 3 && trial.blockedtask_colorshapetest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colorshapetest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>



I thought I copied all three blocks and associated elements with this, but apparently I didn't.
Can you please advise again on how to adapt the script?

Best regards,

Bob Ramakers

> I did the following but now I have only another copy of the instruction slide

The block starts with an instruction trial:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

The instruction item that trial displays is determined by

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>
.
You need to add instruction items for the test blocks and adjust the item number values.selectinstruct is set to /onblockbegin accordingly.

Further, the block then invokes <trial selecblocketraining>

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

That <trial> then invokes the training trials via /branch

<trial selectblockedtraining>
/branch = [if (script.currentblock == "blockedtask_shapetraining") trial.blockedtask_shapetraining]
/branch = [if (script.currentblock == "blockedtask_colortraining") trial.blockedtask_colortraining]
/branch = [if (script.currentblock == "blockedtask_colorshapetraining") trial.blockedtask_colorshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentshapetraining") trial.blockedtask_bivalentshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentcolortraining") trial.blockedtask_bivalentcolortraining]
/trialduration = 0
/recorddata = false
</trial>

For context, look at how the already existing test blocks function -- they do so in basically the same way:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

<block blocked_color>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

Start with an instruction trial -- <trial blockedtestinstruct> -- with the instruction item selected /onblockbegin via values.selectinstruct.

Then move to a selection trial -- <trial selectblockedtrial> -- with the requisite /branch logic

<trial selectblockedtrial>
/branch = [if (script.currentblock == "blocked_shape") trial.blockedtask_bivalentshapetest else trial.blockedtask_bivalentcolortest]
/trialduration = 0
/recorddata = false
</trial>

to invoke the proper type of trial (<trial blockedtask_bivalentshapetest> for <block blocked_shape>; <trial .blockedtask_bivalentcolortest> for <block blocked_color>).

This continues until the <block>'s /stop condition is met:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>


Dear Dave,

I corrected the trial to:

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


And the accompanying block to:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = blockedtestinstruct; 2= selectblockedtrial]
/recorddata = true
</block>



Now I get the correcet instruction, followed by only 1 trial, though I want to get 'blocked_numbertrials'.
Can you please advise once more?

Best regards,

Bob Ramakers
By Dave - 3/14/2017

BobRamakers - Tuesday, March 14, 2017
Dave - Monday, March 13, 2017
BobRamakers - Monday, March 13, 2017
Hi Dave,

Thank you again for your response.
I did the following but now I have only another copy of the instruction slide, no new test trials.

- Copied the blocks in all 4 <expt> and renamed these (3 = noreplace(shapetest); 5 = noreplace(colortest); and 7 = noreplace(colorshapetest);)
- Copied the following in the BLOCKED TASK: TEST BLOCKS



<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colortest>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colorshapetest>
/onblockbegin = [values.selectinstruct = 3]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>



- Copied the following in BLOCKED TASK: TEST TRIALS



<trial blockedtask_shapetest>
/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

<trial blockedtask_colortest>
/ontrialbegin = [values.categorizationtask = "Kleur"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 3 else values.selectstim = 4]
/ontrialbegin = [if (values.selectstim == 3) values.color = "Rood" else values.color = "Groen"]
/ontrialbegin = [values.shape = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 3 && trial.blockedtask_colortest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colortest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


<trial blockedtask_colorshapetest>
/ontrialbegin = [values.selectstim = list.blocked_trainingB.nextvalue]
/ontrialbegin = [if (values.selectstim < 3) values.categorizationtask = "Vorm" else values.categorizationtask = "Kleur"]

/ontrialbegin = [if (values.selectstim == 1) {values.shape = "Cirkel"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 2) {values.shape = "Driehoek"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 3) {values.shape = ""; values.color = "Rood"}]
/ontrialbegin = [if (values.selectstim == 4) {values.shape = ""; values.color = "Groen"}]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle, values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_colorshapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_colorshapetest.response == values.responsekey_triangle) ||
(values.selectstim == 3 && trial.blockedtask_colorshapetest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colorshapetest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>



I thought I copied all three blocks and associated elements with this, but apparently I didn't.
Can you please advise again on how to adapt the script?

Best regards,

Bob Ramakers

> I did the following but now I have only another copy of the instruction slide

The block starts with an instruction trial:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

The instruction item that trial displays is determined by

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>
.
You need to add instruction items for the test blocks and adjust the item number values.selectinstruct is set to /onblockbegin accordingly.

Further, the block then invokes <trial selecblocketraining>

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

That <trial> then invokes the training trials via /branch

<trial selectblockedtraining>
/branch = [if (script.currentblock == "blockedtask_shapetraining") trial.blockedtask_shapetraining]
/branch = [if (script.currentblock == "blockedtask_colortraining") trial.blockedtask_colortraining]
/branch = [if (script.currentblock == "blockedtask_colorshapetraining") trial.blockedtask_colorshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentshapetraining") trial.blockedtask_bivalentshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentcolortraining") trial.blockedtask_bivalentcolortraining]
/trialduration = 0
/recorddata = false
</trial>

For context, look at how the already existing test blocks function -- they do so in basically the same way:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

<block blocked_color>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

Start with an instruction trial -- <trial blockedtestinstruct> -- with the instruction item selected /onblockbegin via values.selectinstruct.

Then move to a selection trial -- <trial selectblockedtrial> -- with the requisite /branch logic

<trial selectblockedtrial>
/branch = [if (script.currentblock == "blocked_shape") trial.blockedtask_bivalentshapetest else trial.blockedtask_bivalentcolortest]
/trialduration = 0
/recorddata = false
</trial>

to invoke the proper type of trial (<trial blockedtask_bivalentshapetest> for <block blocked_shape>; <trial .blockedtask_bivalentcolortest> for <block blocked_color>).

This continues until the <block>'s /stop condition is met:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>


Dear Dave,

I corrected the trial to:

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


And the accompanying block to:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = blockedtestinstruct; 2= selectblockedtrial]
/recorddata = true
</block>



Now I get the correcet instruction, followed by only 1 trial, though I want to get 'blocked_numbertrials'.
Can you please advise once more?

Best regards,

Bob Ramakers


I have to guess because the code you posted does not contain many of the potentially relevant parts, but the /branch in

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

would appear to point to the *wrong* ITI-trial. You'll want to /branch to

/branch = [trial.blockedtask_iti]


which in turn will /branch back to

<trial blockedtask_iti>
/ontrialend = [values.countblockedtrials += 1]
/trialduration = parameters.iti
/recorddata = false
/branch = [trial.selectblockedtrial]
</trial>

By BobRamakers - 3/15/2017

Dave - Tuesday, March 14, 2017
BobRamakers - Tuesday, March 14, 2017
Dave - Monday, March 13, 2017
BobRamakers - Monday, March 13, 2017
Hi Dave,

Thank you again for your response.
I did the following but now I have only another copy of the instruction slide, no new test trials.

- Copied the blocks in all 4 <expt> and renamed these (3 = noreplace(shapetest); 5 = noreplace(colortest); and 7 = noreplace(colorshapetest);)
- Copied the following in the BLOCKED TASK: TEST BLOCKS



<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colortest>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colorshapetest>
/onblockbegin = [values.selectinstruct = 3]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>



- Copied the following in BLOCKED TASK: TEST TRIALS



<trial blockedtask_shapetest>
/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

<trial blockedtask_colortest>
/ontrialbegin = [values.categorizationtask = "Kleur"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 3 else values.selectstim = 4]
/ontrialbegin = [if (values.selectstim == 3) values.color = "Rood" else values.color = "Groen"]
/ontrialbegin = [values.shape = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 3 && trial.blockedtask_colortest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colortest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


<trial blockedtask_colorshapetest>
/ontrialbegin = [values.selectstim = list.blocked_trainingB.nextvalue]
/ontrialbegin = [if (values.selectstim < 3) values.categorizationtask = "Vorm" else values.categorizationtask = "Kleur"]

/ontrialbegin = [if (values.selectstim == 1) {values.shape = "Cirkel"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 2) {values.shape = "Driehoek"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 3) {values.shape = ""; values.color = "Rood"}]
/ontrialbegin = [if (values.selectstim == 4) {values.shape = ""; values.color = "Groen"}]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle, values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_colorshapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_colorshapetest.response == values.responsekey_triangle) ||
(values.selectstim == 3 && trial.blockedtask_colorshapetest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colorshapetest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>



I thought I copied all three blocks and associated elements with this, but apparently I didn't.
Can you please advise again on how to adapt the script?

Best regards,

Bob Ramakers

> I did the following but now I have only another copy of the instruction slide

The block starts with an instruction trial:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

The instruction item that trial displays is determined by

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>
.
You need to add instruction items for the test blocks and adjust the item number values.selectinstruct is set to /onblockbegin accordingly.

Further, the block then invokes <trial selecblocketraining>

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

That <trial> then invokes the training trials via /branch

<trial selectblockedtraining>
/branch = [if (script.currentblock == "blockedtask_shapetraining") trial.blockedtask_shapetraining]
/branch = [if (script.currentblock == "blockedtask_colortraining") trial.blockedtask_colortraining]
/branch = [if (script.currentblock == "blockedtask_colorshapetraining") trial.blockedtask_colorshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentshapetraining") trial.blockedtask_bivalentshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentcolortraining") trial.blockedtask_bivalentcolortraining]
/trialduration = 0
/recorddata = false
</trial>

For context, look at how the already existing test blocks function -- they do so in basically the same way:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

<block blocked_color>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

Start with an instruction trial -- <trial blockedtestinstruct> -- with the instruction item selected /onblockbegin via values.selectinstruct.

Then move to a selection trial -- <trial selectblockedtrial> -- with the requisite /branch logic

<trial selectblockedtrial>
/branch = [if (script.currentblock == "blocked_shape") trial.blockedtask_bivalentshapetest else trial.blockedtask_bivalentcolortest]
/trialduration = 0
/recorddata = false
</trial>

to invoke the proper type of trial (<trial blockedtask_bivalentshapetest> for <block blocked_shape>; <trial .blockedtask_bivalentcolortest> for <block blocked_color>).

This continues until the <block>'s /stop condition is met:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>


Dear Dave,

I corrected the trial to:

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


And the accompanying block to:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = blockedtestinstruct; 2= selectblockedtrial]
/recorddata = true
</block>



Now I get the correcet instruction, followed by only 1 trial, though I want to get 'blocked_numbertrials'.
Can you please advise once more?

Best regards,

Bob Ramakers


I have to guess because the code you posted does not contain many of the potentially relevant parts, but the /branch in

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

would appear to point to the *wrong* ITI-trial. You'll want to /branch to

/branch = [trial.blockedtask_iti]


which in turn will /branch back to

<trial blockedtask_iti>
/ontrialend = [values.countblockedtrials += 1]
/trialduration = parameters.iti
/recorddata = false
/branch = [trial.selectblockedtrial]
</trial>


Hi Dave,

Thank you again for your answer.
The script is working fine now.

Last thing I want to change: I would like to have random blocks with equal numbers of the items. To elaborate: In the shape test, I would like to have 32 trials with an equal division of circles and triangles (both 16). Same goes for color test, color shape test (8 circles, 8 triangles, 8 green, 8 red). In the mixed word short CSI I would like to have 16 SHAPE trials and 16 COLOR trials, with then (4 triangle red, 4 triangle green, 4 circle red, 4 circle green).

Could you please advise on this? Then I can finalize the experiment :)

Best regards,

Bob Ramakers
By Dave - 3/15/2017

BobRamakers - Wednesday, March 15, 2017
Dave - Tuesday, March 14, 2017
BobRamakers - Tuesday, March 14, 2017
Dave - Monday, March 13, 2017
BobRamakers - Monday, March 13, 2017
Hi Dave,

Thank you again for your response.
I did the following but now I have only another copy of the instruction slide, no new test trials.

- Copied the blocks in all 4 <expt> and renamed these (3 = noreplace(shapetest); 5 = noreplace(colortest); and 7 = noreplace(colorshapetest);)
- Copied the following in the BLOCKED TASK: TEST BLOCKS



<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colortest>
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

<block colorshapetest>
/onblockbegin = [values.selectinstruct = 3]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>



- Copied the following in BLOCKED TASK: TEST TRIALS



<trial blockedtask_shapetest>
/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

<trial blockedtask_colortest>
/ontrialbegin = [values.categorizationtask = "Kleur"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 3 else values.selectstim = 4]
/ontrialbegin = [if (values.selectstim == 3) values.color = "Rood" else values.color = "Groen"]
/ontrialbegin = [values.shape = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 3 && trial.blockedtask_colortest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colortest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


<trial blockedtask_colorshapetest>
/ontrialbegin = [values.selectstim = list.blocked_trainingB.nextvalue]
/ontrialbegin = [if (values.selectstim < 3) values.categorizationtask = "Vorm" else values.categorizationtask = "Kleur"]

/ontrialbegin = [if (values.selectstim == 1) {values.shape = "Cirkel"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 2) {values.shape = "Driehoek"; values.color = ""}]
/ontrialbegin = [if (values.selectstim == 3) {values.shape = ""; values.color = "Rood"}]
/ontrialbegin = [if (values.selectstim == 4) {values.shape = ""; values.color = "Groen"}]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle, values.responsekey_red, values.responsekey_green)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_colorshapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_colorshapetest.response == values.responsekey_triangle) ||
(values.selectstim == 3 && trial.blockedtask_colorshapetest.response == values.responsekey_red) ||
(values.selectstim == 4 && trial.blockedtask_colorshapetest.response == values.responsekey_green)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>



I thought I copied all three blocks and associated elements with this, but apparently I didn't.
Can you please advise again on how to adapt the script?

Best regards,

Bob Ramakers

> I did the following but now I have only another copy of the instruction slide

The block starts with an instruction trial:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

The instruction item that trial displays is determined by

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>
.
You need to add instruction items for the test blocks and adjust the item number values.selectinstruct is set to /onblockbegin accordingly.

Further, the block then invokes <trial selecblocketraining>

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = BlockedPracticeInstruct; 2= selectblockedtraining]
/recorddata = true
</block>

That <trial> then invokes the training trials via /branch

<trial selectblockedtraining>
/branch = [if (script.currentblock == "blockedtask_shapetraining") trial.blockedtask_shapetraining]
/branch = [if (script.currentblock == "blockedtask_colortraining") trial.blockedtask_colortraining]
/branch = [if (script.currentblock == "blockedtask_colorshapetraining") trial.blockedtask_colorshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentshapetraining") trial.blockedtask_bivalentshapetraining]
/branch = [if (script.currentblock == "blockedtask_bivalentcolortraining") trial.blockedtask_bivalentcolortraining]
/trialduration = 0
/recorddata = false
</trial>

For context, look at how the already existing test blocks function -- they do so in basically the same way:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

<block blocked_color>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 2]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>

Start with an instruction trial -- <trial blockedtestinstruct> -- with the instruction item selected /onblockbegin via values.selectinstruct.

Then move to a selection trial -- <trial selectblockedtrial> -- with the requisite /branch logic

<trial selectblockedtrial>
/branch = [if (script.currentblock == "blocked_shape") trial.blockedtask_bivalentshapetest else trial.blockedtask_bivalentcolortest]
/trialduration = 0
/recorddata = false
</trial>

to invoke the proper type of trial (<trial blockedtask_bivalentshapetest> for <block blocked_shape>; <trial .blockedtask_bivalentcolortest> for <block blocked_color>).

This continues until the <block>'s /stop condition is met:

<block blocked_shape>
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/postinstructions = (blockfeedback)
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.count_color = 0; values.count_shape = 0; values.count_corrcolor = 0; values.count_corrshape = 0;
values.sumrt_corrcolor = 0; values.sumrt_corrshape = 0; values.countblockedtrials = 0]
/trials = [1 = blockedtestinstruct; 2 = selectblockedtrial]
</block>


Dear Dave,

I corrected the trial to:

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>


And the accompanying block to:

<block shapetest>
/onblockbegin = [values.selectinstruct = 1]
/onblockbegin = [values.countblockedtrials = 0]
/stop = [values.countblockedtrials == parameters.blocked_numbertrials]
/trials = [1 = blockedtestinstruct; 2= selectblockedtrial]
/recorddata = true
</block>



Now I get the correcet instruction, followed by only 1 trial, though I want to get 'blocked_numbertrials'.
Can you please advise once more?

Best regards,

Bob Ramakers


I have to guess because the code you posted does not contain many of the potentially relevant parts, but the /branch in

<trial blockedtask_shapetest>

/ontrialbegin = [values.categorizationtask = "Vorm"]
/ontrialbegin = [values.helper = list.blocked_testtrials.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]
/ontrialbegin = [if (values.selectstim == 1) values.shape = "CIRKEL" else values.shape = "DRIEHOEK"]
/ontrialbegin = [values.color = ""]

/stimulustimes = [0 = stimulus]
/ beginresponsetime = 0
/ responseinterrupt = immediate
/validresponse = (values.responsekey_circle, values.responsekey_triangle)
/iscorrectresponse = [(values.selectstim == 1 && trial.blockedtask_shapetest.response == values.responsekey_circle) ||
(values.selectstim == 2 && trial.blockedtask_shapetest.response == values.responsekey_triangle)]
/monkeyresponse = (30, 38)
/recorddata = true
/ontrialend = [values.stimulus = picture.stimulus.currentitem]
/branch = [trial.blockedtasktraining_iti]
</trial>

would appear to point to the *wrong* ITI-trial. You'll want to /branch to

/branch = [trial.blockedtask_iti]


which in turn will /branch back to

<trial blockedtask_iti>
/ontrialend = [values.countblockedtrials += 1]
/trialduration = parameters.iti
/recorddata = false
/branch = [trial.selectblockedtrial]
</trial>


Hi Dave,

Thank you again for your answer.
The script is working fine now.

Last thing I want to change: I would like to have random blocks with equal numbers of the items. To elaborate: In the shape test, I would like to have 32 trials with an equal division of circles and triangles (both 16). Same goes for color test, color shape test (8 circles, 8 triangles, 8 green, 8 red). In the mixed word short CSI I would like to have 16 SHAPE trials and 16 COLOR trials, with then (4 triangle red, 4 triangle green, 4 circle red, 4 circle green).

Could you please advise on this? Then I can finalize the experiment :)

Best regards,

Bob Ramakers

Look at how stimulus selection works by studying the training <trial> elements. Example:

<trial blockedtask_shapetraining>
/ontrialbegin = [values.categorizationtask = "Shape"]
/ontrialbegin = [values.helper = list.blocked_trainingA.nextvalue]
/ontrialbegin = [if (values.helper == 1) values.selectstim = 1 else values.selectstim = 2]

/ontrialbegin = [if (values.selectstim == 1) values.shape = "Circle" else values.shape = "Triangle"]
/ontrialbegin = [values.color = ""]
...
</trial>

samples a value from <list blocked_trainingA>. The shape presented is determined by the value sampled (cf. values.selectstim).

<list blocked_trainingA>
/items = (1,2)
/poolsize = parameters.blocked_numberpracticetrials
/replace = false
/resetinterval = 1
</list>

The list contains the numbers 1 and 2 in equal proportions, the total number of items in the list is determined by parameters.blocked_numberpracticetrials.

Apply the same approach to your test trials.
By BobRamakers - 3/30/2017

Dear Dave,

I am sorry for the delay in replying but the test works perfectly now.
Thank you for your great support!

Best regards,

Bob Ramakers