Responsetrial: how to select one, and at the same time skip the other one


Responsetrial: how to select one, and at the same time skip the other...
Author
Message
wj_y
wj_y
Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)
Group: Forum Members
Posts: 3, Visits: 8
Hi all,
I am trying to make a script to assign different trials (trial B / C) based on the response the user give in trial A. I have 100 trial in A, 100 in B and 100 in C, all in sequence. So for the 1st trial A, if the user choose "j", they should go to the 1st trial B, and if the choose "k", it will go to the 1st trial C. At the same time, the trial that does not get chosen should never appear again. 
Right now, what I have is: if on the 1st trial A, they choose "j" and go to 1st B. Then in the 2nd trial A, when they choose "k", they will go to the 1st trial C instead of the 2nd C. I tried "skip", but it didn't work. How should I solve this problem? Thank you!!

My script is here:
<trial A>
/stimulustimes= [0= T1_11, T1_12, j, k]
/timeout = 5000
/ validresponse = ("j","k")
/ beginresponsetime = 0
/ responseinterrupt = trial
/ responsetrial == ("j", trial.B)
/ responsetrial == ("k", trial.C)
</trial>

<trial B>
/stimulustimes= [0=T1_21, T1_Q]
/timeout = 5000
/ skip = [trial.A.response == "k"]
</trial>

<trial C>
/stimulustimes= [0=T1_22, T1_2_Q]
/timeout = 5000
/ skip = [trial.A.response == "j"]
</trial>

<block test_1>
/ trials = [1-100=sequence(A)]
</block>

Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 12K, Visits: 98K
wj_y - Friday, December 8, 2017
Hi all,
I am trying to make a script to assign different trials (trial B / C) based on the response the user give in trial A. I have 100 trial in A, 100 in B and 100 in C, all in sequence. So for the 1st trial A, if the user choose "j", they should go to the 1st trial B, and if the choose "k", it will go to the 1st trial C. At the same time, the trial that does not get chosen should never appear again. 
Right now, what I have is: if on the 1st trial A, they choose "j" and go to 1st B. Then in the 2nd trial A, when they choose "k", they will go to the 1st trial C instead of the 2nd C. I tried "skip", but it didn't work. How should I solve this problem? Thank you!!

My script is here:
<trial A>
/stimulustimes= [0= T1_11, T1_12, j, k]
/timeout = 5000
/ validresponse = ("j","k")
/ beginresponsetime = 0
/ responseinterrupt = trial
/ responsetrial == ("j", trial.B)
/ responsetrial == ("k", trial.C)
</trial>

<trial B>
/stimulustimes= [0=T1_21, T1_Q]
/timeout = 5000
/ skip = [trial.A.response == "k"]
</trial>

<trial C>
/stimulustimes= [0=T1_22, T1_2_Q]
/timeout = 5000
/ skip = [trial.A.response == "j"]
</trial>

<block test_1>
/ trials = [1-100=sequence(A)]
</block>

Sorry, I don't understand your description. Why are there 100 A trials, i.e. why do you wish to present the choice to either run a B or C trial 100 times?

This doesn't make sense to me, especially in light of this sentence: "[...] the trial that does not get chosen should never appear again."

So, suppose you run one A trial, and the participant presses "k". What is supposed to happen then? Is the participant supposed to then receive 100 C trials? I.e. no further A and never any B trials? Or is it something else? Please explain.

wj_y
wj_y
Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)
Group: Forum Members
Posts: 3, Visits: 8
Dave - Friday, December 8, 2017
wj_y - Friday, December 8, 2017
Hi all,
I am trying to make a script to assign different trials (trial B / C) based on the response the user give in trial A. I have 100 trial in A, 100 in B and 100 in C, all in sequence. So for the 1st trial A, if the user choose "j", they should go to the 1st trial B, and if the choose "k", it will go to the 1st trial C. At the same time, the trial that does not get chosen should never appear again. 
Right now, what I have is: if on the 1st trial A, they choose "j" and go to 1st B. Then in the 2nd trial A, when they choose "k", they will go to the 1st trial C instead of the 2nd C. I tried "skip", but it didn't work. How should I solve this problem? Thank you!!

My script is here:
<trial A>
/stimulustimes= [0= T1_11, T1_12, j, k]
/timeout = 5000
/ validresponse = ("j","k")
/ beginresponsetime = 0
/ responseinterrupt = trial
/ responsetrial == ("j", trial.B)
/ responsetrial == ("k", trial.C)
</trial>

<trial B>
/stimulustimes= [0=T1_21, T1_Q]
/timeout = 5000
/ skip = [trial.A.response == "k"]
</trial>

<trial C>
/stimulustimes= [0=T1_22, T1_2_Q]
/timeout = 5000
/ skip = [trial.A.response == "j"]
</trial>

<block test_1>
/ trials = [1-100=sequence(A)]
</block>

Sorry, I don't understand your description. Why are there 100 A trials, i.e. why do you wish to present the choice to either run a B or C trial 100 times?

This doesn't make sense to me, especially in light of this sentence: "[...] the trial that does not get chosen should never appear again."

So, suppose you run one A trial, and the participant presses "k". What is supposed to happen then? Is the participant supposed to then receive 100 C trials? I.e. no further A and never any B trials? Or is it something else? Please explain.

Thank you for your reply! And so sorry I didn't explain it clearly.
So basically, there will be 100 trials in A, 100 in B and 100 in C, A B C represent different kinds of questions (like 3 blocks), and within A/B/C will be same questions but different stimuli. And A, B, C share identical stimuli, so the stimulus in A[1] is the same as B[1] and C[1];  stimulus of A[2] is the same as B[2] and C[2], but stimulus in A[1] is different from A[2].

What I expect is that participant will first do a trial A, if the response is "j", they should then go to the 1st trial in B, after that, they will go back to the second trial A (different stimuli, same format). Here, if they choose "k", they should receive the corresponding trial C, which is the second trial in C. And because the participant does not choose "k" in the first trial of A, the first trial in C should not appear again. The correct procedure should be: A[1]→B[1]/C[1]→A[2]→B[2]/C[2]→A[3]→B[3]/C[3]→...→A[100]→B[100]/C[100]

But my script is not working, because it will go through all the trials in B and C in an ascending sequence, but not skip the ones aren't chosen, so the stimuli aren't matching. So if participant responds "j" in the first trial of A, they receive 1st trial in B, but when they go back to the second trial of A, if they choose "k", they will go to the 1st trial in C, but not the second trial in C. It doesn't go to the corresponding trial B/C, but just the next trial B/C in sequence. 
Does that make more sense? Thank you so much!! Let me know if that's still not clear enough!


Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 12K, Visits: 98K
wj_y - Friday, December 8, 2017
Dave - Friday, December 8, 2017
wj_y - Friday, December 8, 2017
Hi all,
I am trying to make a script to assign different trials (trial B / C) based on the response the user give in trial A. I have 100 trial in A, 100 in B and 100 in C, all in sequence. So for the 1st trial A, if the user choose "j", they should go to the 1st trial B, and if the choose "k", it will go to the 1st trial C. At the same time, the trial that does not get chosen should never appear again. 
Right now, what I have is: if on the 1st trial A, they choose "j" and go to 1st B. Then in the 2nd trial A, when they choose "k", they will go to the 1st trial C instead of the 2nd C. I tried "skip", but it didn't work. How should I solve this problem? Thank you!!

My script is here:
<trial A>
/stimulustimes= [0= T1_11, T1_12, j, k]
/timeout = 5000
/ validresponse = ("j","k")
/ beginresponsetime = 0
/ responseinterrupt = trial
/ responsetrial == ("j", trial.B)
/ responsetrial == ("k", trial.C)
</trial>

<trial B>
/stimulustimes= [0=T1_21, T1_Q]
/timeout = 5000
/ skip = [trial.A.response == "k"]
</trial>

<trial C>
/stimulustimes= [0=T1_22, T1_2_Q]
/timeout = 5000
/ skip = [trial.A.response == "j"]
</trial>

<block test_1>
/ trials = [1-100=sequence(A)]
</block>

Sorry, I don't understand your description. Why are there 100 A trials, i.e. why do you wish to present the choice to either run a B or C trial 100 times?

This doesn't make sense to me, especially in light of this sentence: "[...] the trial that does not get chosen should never appear again."

So, suppose you run one A trial, and the participant presses "k". What is supposed to happen then? Is the participant supposed to then receive 100 C trials? I.e. no further A and never any B trials? Or is it something else? Please explain.

Thank you for your reply! And so sorry I didn't explain it clearly.
So basically, there will be 100 trials in A, 100 in B and 100 in C, A B C represent different kinds of questions (like 3 blocks), and within A/B/C will be same questions but different stimuli. And A, B, C share identical stimuli, so the stimulus in A[1] is the same as B[1] and C[1];  stimulus of A[2] is the same as B[2] and C[2], but stimulus in A[1] is different from A[2].

What I expect is that participant will first do a trial A, if the response is "j", they should then go to the 1st trial in B, after that, they will go back to the second trial A (different stimuli, same format). Here, if they choose "k", they should receive the corresponding trial C, which is the second trial in C. And because the participant does not choose "k" in the first trial of A, the first trial in C should not appear again. The correct procedure should be: A[1]→B[1]/C[1]→A[2]→B[2]/C[2]→A[3]→B[3]/C[3]→...→A[100]→B[100]/C[100]

But my script is not working, because it will go through all the trials in B and C in an ascending sequence, but not skip the ones aren't chosen, so the stimuli aren't matching. So if participant responds "j" in the first trial of A, they receive 1st trial in B, but when they go back to the second trial of A, if they choose "k", they will go to the 1st trial in C, but not the second trial in C. It doesn't go to the corresponding trial B/C, but just the next trial B/C in sequence. 
Does that make more sense? Thank you so much!! Let me know if that's still not clear enough!


Ah, thanks for the clarification -- that makes sense. Here's how you do this (I'm reducing the number of stimuli/trials to 10 in sequential order for the sake of illustration):

<trial a>
/ stimulusframes = [1=a_stimulus]
/ timeout = 5000
/ validresponse = ("j","k")
/ branch = [
    if (computer.scancodetochar(trial.a.response) == "j")
    trial.b;
]
/ branch = [
    if (computer.scancodetochar(trial.a.response) == "k")
    trial.c;
]
</trial>

<trial b>
/ stimulusframes = [1=b_stimulus]
/ timeout = 5000
/ validresponse = (0)
</trial>

<trial c>
/ stimulusframes = [1=c_stimulus]
/ timeout = 5000
/ validresponse = (0)
</trial>

<text a_stimulus>
/ items = a_items
/ select = sequence
</text>

<text b_stimulus>
/ items = b_items
/ select = text.a_stimulus.currentindex
</text>

<text c_stimulus>
/ items = c_items
/ select = text.a_stimulus.currentindex
</text>

<item a_items>
/ 1 = "A 01"
/ 2 = "A 02"
/ 3 = "A 03"
/ 4 = "A 04"
/ 5 = "A 05"
/ 6 = "A 06"
/ 7 = "A 07"
/ 8 = "A 08"
/ 9 = "A 09"
/ 10 = "A 10"
</item>

<item b_items>
/ 1 = "B 01"
/ 2 = "B 02"
/ 3 = "B 03"
/ 4 = "B 04"
/ 5 = "B 05"
/ 6 = "B 06"
/ 7 = "B 07"
/ 8 = "B 08"
/ 9 = "B 09"
/ 10 = "B 10"
</item>

<item c_items>
/ 1 = "C 01"
/ 2 = "C 02"
/ 3 = "C 03"
/ 4 = "C 04"
/ 5 = "C 05"
/ 6 = "C 06"
/ 7 = "C 07"
/ 8 = "C 08"
/ 9 = "C 09"
/ 10 = "C 10"
</item>

<block exampleblock>
/ trials = [1-10 = a]
</block>


wj_y
wj_y
Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)Associate Member (220 reputation)
Group: Forum Members
Posts: 3, Visits: 8
Dave - Friday, December 8, 2017
wj_y - Friday, December 8, 2017
Dave - Friday, December 8, 2017
wj_y - Friday, December 8, 2017
Hi all,
I am trying to make a script to assign different trials (trial B / C) based on the response the user give in trial A. I have 100 trial in A, 100 in B and 100 in C, all in sequence. So for the 1st trial A, if the user choose "j", they should go to the 1st trial B, and if the choose "k", it will go to the 1st trial C. At the same time, the trial that does not get chosen should never appear again. 
Right now, what I have is: if on the 1st trial A, they choose "j" and go to 1st B. Then in the 2nd trial A, when they choose "k", they will go to the 1st trial C instead of the 2nd C. I tried "skip", but it didn't work. How should I solve this problem? Thank you!!

My script is here:
<trial A>
/stimulustimes= [0= T1_11, T1_12, j, k]
/timeout = 5000
/ validresponse = ("j","k")
/ beginresponsetime = 0
/ responseinterrupt = trial
/ responsetrial == ("j", trial.B)
/ responsetrial == ("k", trial.C)
</trial>

<trial B>
/stimulustimes= [0=T1_21, T1_Q]
/timeout = 5000
/ skip = [trial.A.response == "k"]
</trial>

<trial C>
/stimulustimes= [0=T1_22, T1_2_Q]
/timeout = 5000
/ skip = [trial.A.response == "j"]
</trial>

<block test_1>
/ trials = [1-100=sequence(A)]
</block>

Sorry, I don't understand your description. Why are there 100 A trials, i.e. why do you wish to present the choice to either run a B or C trial 100 times?

This doesn't make sense to me, especially in light of this sentence: "[...] the trial that does not get chosen should never appear again."

So, suppose you run one A trial, and the participant presses "k". What is supposed to happen then? Is the participant supposed to then receive 100 C trials? I.e. no further A and never any B trials? Or is it something else? Please explain.

Thank you for your reply! And so sorry I didn't explain it clearly.
So basically, there will be 100 trials in A, 100 in B and 100 in C, A B C represent different kinds of questions (like 3 blocks), and within A/B/C will be same questions but different stimuli. And A, B, C share identical stimuli, so the stimulus in A[1] is the same as B[1] and C[1];  stimulus of A[2] is the same as B[2] and C[2], but stimulus in A[1] is different from A[2].

What I expect is that participant will first do a trial A, if the response is "j", they should then go to the 1st trial in B, after that, they will go back to the second trial A (different stimuli, same format). Here, if they choose "k", they should receive the corresponding trial C, which is the second trial in C. And because the participant does not choose "k" in the first trial of A, the first trial in C should not appear again. The correct procedure should be: A[1]→B[1]/C[1]→A[2]→B[2]/C[2]→A[3]→B[3]/C[3]→...→A[100]→B[100]/C[100]

But my script is not working, because it will go through all the trials in B and C in an ascending sequence, but not skip the ones aren't chosen, so the stimuli aren't matching. So if participant responds "j" in the first trial of A, they receive 1st trial in B, but when they go back to the second trial of A, if they choose "k", they will go to the 1st trial in C, but not the second trial in C. It doesn't go to the corresponding trial B/C, but just the next trial B/C in sequence. 
Does that make more sense? Thank you so much!! Let me know if that's still not clear enough!


Ah, thanks for the clarification -- that makes sense. Here's how you do this (I'm reducing the number of stimuli/trials to 10 in sequential order for the sake of illustration):

<trial a>
/ stimulusframes = [1=a_stimulus]
/ timeout = 5000
/ validresponse = ("j","k")
/ branch = [
    if (computer.scancodetochar(trial.a.response) == "j")
    trial.b;
]
/ branch = [
    if (computer.scancodetochar(trial.a.response) == "k")
    trial.c;
]
</trial>

<trial b>
/ stimulusframes = [1=b_stimulus]
/ timeout = 5000
/ validresponse = (0)
</trial>

<trial c>
/ stimulusframes = [1=c_stimulus]
/ timeout = 5000
/ validresponse = (0)
</trial>

<text a_stimulus>
/ items = a_items
/ select = sequence
</text>

<text b_stimulus>
/ items = b_items
/ select = text.a_stimulus.currentindex
</text>

<text c_stimulus>
/ items = c_items
/ select = text.a_stimulus.currentindex
</text>

<item a_items>
/ 1 = "A 01"
/ 2 = "A 02"
/ 3 = "A 03"
/ 4 = "A 04"
/ 5 = "A 05"
/ 6 = "A 06"
/ 7 = "A 07"
/ 8 = "A 08"
/ 9 = "A 09"
/ 10 = "A 10"
</item>

<item b_items>
/ 1 = "B 01"
/ 2 = "B 02"
/ 3 = "B 03"
/ 4 = "B 04"
/ 5 = "B 05"
/ 6 = "B 06"
/ 7 = "B 07"
/ 8 = "B 08"
/ 9 = "B 09"
/ 10 = "B 10"
</item>

<item c_items>
/ 1 = "C 01"
/ 2 = "C 02"
/ 3 = "C 03"
/ 4 = "C 04"
/ 5 = "C 05"
/ 6 = "C 06"
/ 7 = "C 07"
/ 8 = "C 08"
/ 9 = "C 09"
/ 10 = "C 10"
</item>

<block exampleblock>
/ trials = [1-10 = a]
</block>


Thank you so much!! That works perfectly!
Have a good weekend!
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search