I need help to program an Experiment to test a persons flexibility


Author
Message
Theo Ero
Theo Ero
New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)New Member (23 reputation)
Group: Forum Members
Posts: 3, Visits: 16
Hello all!

I am programming an Experiment where a letter and number are presented together either on the left or Right side of the sreen​.

The given letters are:
B, D, E, ​G, H, L, N, R, T
The given numbers are:
​1, 2, 3, 4, 5, 6, 7, 8, 9
(all letters and numbers are Picture-Elements)

​The participants are able to react on the Symbols with the following keys of the Keyboard:
Symbol on the left side: 'A'
Symbol on the Right side: 'L'

​The Task is to press either the button for the letter or for the number; so the Task changes at each Trial. At the first Trial the participant has to push the button for the letters Position.

​The Arrangement is:
Trial​ 1: letter position
Trial 2: number position
Trial 3: letter position
Trial 4: number position
etc.

Question 1: All possible combinations:
​Is there a "quick" command to create all combinations or do I have to program each Trial separately?
For Example:
​Letter 'B' on the left side and number '1' on the Right side = Trial.b_1
​Letter 'B' on the right side and number '1' on the left side = Trial.1_b
etc.​

Question 2: Circle around first Trial:
Is it possible to insert a White circle (Picture-element) around the target of the first Trial (letter) as an cue for orientation?

Question 3: Circle around Target of the next Trial after invalid previous trial
I would like to program that everytime ​the participant presses an invalid key, the target of the next Trial gets an circle, to help them Re-orienting.

If you Need further Information, feel free to ask!​
​Thank you very much!
Theo​​​​​​​​​​​​​​​​​​​​​​​
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
Theo Ero - 7/17/2020
Hello all!

I am programming an Experiment where a letter and number are presented together either on the left or Right side of the sreen.

The given letters are:
B, D, E, G, H, L, N, R, T
The given numbers are:
1, 2, 3, 4, 5, 6, 7, 8, 9
(all letters and numbers are Picture-Elements)

The participants are able to react on the Symbols with the following keys of the Keyboard:
Symbol on the left side: 'A'
Symbol on the Right side: 'L'

The Task is to press either the button for the letter or for the number; so the Task changes at each Trial. At the first Trial the participant has to push the button for the letters Position.

The Arrangement is:
Trial 1: letter position
Trial 2: number position
Trial 3: letter position
Trial 4: number position
etc.

Question 1: All possible combinations:
Is there a "quick" command to create all combinations or do I have to program each Trial separately?
For Example:
Letter 'B' on the left side and number '1' on the Right side = Trial.b_1
Letter 'B' on the right side and number '1' on the left side = Trial.1_b
etc.

Question 2: Circle around first Trial:
Is it possible to insert a White circle (Picture-element) around the target of the first Trial (letter) as an cue for orientation?

Question 3: Circle around Target of the next Trial after invalid previous trial
I would like to program that everytime the participant presses an invalid key, the target of the next Trial gets an circle, to help them Re-orienting.

If you Need further Information, feel free to ask!
Thank you very much!
Theo

Re. 1) You can use list elements to vary those things if you want to. That's not necessarily quicker.
Re. 2) and 3), I believe this has been discussed before? https://www.millisecond.com/forums/Topic29259.aspx Not sure what additional information you are looking for.

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
Dave - 7/17/2020
Theo Ero - 7/17/2020
Hello all!

I am programming an Experiment where a letter and number are presented together either on the left or Right side of the sreen.

The given letters are:
B, D, E, G, H, L, N, R, T
The given numbers are:
1, 2, 3, 4, 5, 6, 7, 8, 9
(all letters and numbers are Picture-Elements)

The participants are able to react on the Symbols with the following keys of the Keyboard:
Symbol on the left side: 'A'
Symbol on the Right side: 'L'

The Task is to press either the button for the letter or for the number; so the Task changes at each Trial. At the first Trial the participant has to push the button for the letters Position.

The Arrangement is:
Trial 1: letter position
Trial 2: number position
Trial 3: letter position
Trial 4: number position
etc.

Question 1: All possible combinations:
Is there a "quick" command to create all combinations or do I have to program each Trial separately?
For Example:
Letter 'B' on the left side and number '1' on the Right side = Trial.b_1
Letter 'B' on the right side and number '1' on the left side = Trial.1_b
etc.

Question 2: Circle around first Trial:
Is it possible to insert a White circle (Picture-element) around the target of the first Trial (letter) as an cue for orientation?

Question 3: Circle around Target of the next Trial after invalid previous trial
I would like to program that everytime the participant presses an invalid key, the target of the next Trial gets an circle, to help them Re-orienting.

If you Need further Information, feel free to ask!
Thank you very much!
Theo

Re. 1) You can use list elements to vary those things if you want to. That's not necessarily quicker.
Re. 2) and 3), I believe this has been discussed before? https://www.millisecond.com/forums/Topic29259.aspx Not sure what additional information you are looking for.

Here's a quick example implelemting the letter trials only, i.e. the trialtype where the participant has to respond with the key corresponding to the on-screen position of the letter stimulus. You have 9 letters, 9 digits, and 2 positions (left / right), so there are 9 x 9 x 2 = 162 possible combinations. The code implements all of them per the paired list elements. The target stimulus (letter) is highlighted by a circle on the first trial and whenever a wrong response was made on the previous trial. Implementation of the number trials would be 100% analogous.

<values>
/ letteritemnumber = 1
/ numberitemnumber = 1
/ letterhpos = 0%
/ numberhpos = 0%
/ targetcirclehpos = 0%
/ correctkey = ""
/ trialcounter = 0
/ error = false
</values>

<block example>
/ trials = [1-162 = lettertrial]
</block>

// respond to letter position
<trial lettertrial>
/ ontrialbegin = [
    values.trialcounter += 1;
    values.letteritemnumber = list.letteritemnumber_lettertrial.nextvalue;
    values.numberitemnumber = list.numberitemnumber_lettertrial.nextvalue;
    values.letterhpos = list.letterhpos_lettertrial.nextvalue;
    if (values.letterhpos == 40%) {
        values.numberhpos = 60%;
        values.correctkey = "A";
    } else {
        values.numberhpos = 40%;
        values.correctkey = "L";
    };
]
/ ontrialbegin = [
    if (values.trialcounter <= 1 || values.error) {
        values.targetcirclehpos = values.letterhpos;
        trial.lettertrial.insertstimulusframe(shape.targetcircleouter, 1);
        trial.lettertrial.insertstimulusframe(shape.targetcircleinner, 1);
        trial.lettertrial.insertstimulusframe(text.letter, 1);
    }
]
/ ontrialend = [
    values.error = trial.lettertrial.error;
    trial.lettertrial.resetstimulusframes();
]
/ stimulusframes = [1=letter, number]
/ validresponse = ("A", "L")
/ iscorrectresponse = [
    trial.lettertrial.responsetext == values.correctkey;
]
/ correctmessage = true(correctmsg, 500)
/ errormessage = true(errormsg, 500)
</trial>

<list letteritemnumber_lettertrial>
/ items = (
    1,1,1,1,1,1,1,1,1,
    2,2,2,2,2,2,2,2,2,
    3,3,3,3,3,3,3,3,3,
    4,4,4,4,4,4,4,4,4,
    5,5,5,5,5,5,5,5,5,
    6,6,6,6,6,6,6,6,6,
    7,7,7,7,7,7,7,7,7,
    8,8,8,8,8,8,8,8,8,
    9,9,9,9,9,9,9,9,9,
    1,1,1,1,1,1,1,1,1,
    2,2,2,2,2,2,2,2,2,
    3,3,3,3,3,3,3,3,3,
    4,4,4,4,4,4,4,4,4,
    5,5,5,5,5,5,5,5,5,
    6,6,6,6,6,6,6,6,6,
    7,7,7,7,7,7,7,7,7,
    8,8,8,8,8,8,8,8,8,
    9,9,9,9,9,9,9,9,9)
</list>

<list numberitemnumber_lettertrial>
/ items = (
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9,
    1,2,3,4,5,6,7,8,9)
/ selectionmode = list.letteritemnumber_lettertrial.currentindex
</list>

<list letterhpos_lettertrial>
/ items = (
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    40%,40%,40%,40%,40%,40%,40%,40%,40%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%,
    60%,60%,60%,60%,60%,60%,60%,60%,60%)
/ selectionmode = list.letteritemnumber_lettertrial.currentindex
</list>


<text letter>
/ items = letteritems
/ select = values.letteritemnumber
/ vposition = 50%
/ hposition = values.letterhpos
</text>

<item letteritems>
/ 1 = "B"
/ 2 = "D"
/ 3 = "E"
/ 4 = "G"
/ 5 = "H"
/ 6 = "L"
/ 7 = "N"
/ 8 = "R"
/ 9 = "T"
</item>

<text number>
/ items = numberitems
/ select = values.numberitemnumber
/ vposition = 50%
/ hposition = values.numberhpos
</text>

<item numberitems>
/ 1 = "1"
/ 2 = "2"
/ 3 = "3"
/ 4 = "4"
/ 5 = "5"
/ 6 = "6"
/ 7 = "7"
/ 8 = "8"
/ 9 = "9"
</item>

<shape targetcircleouter>
/ shape = circle
/ size = (10%, 0.1px*display.canvaswidth)
/ color = blue
/ vposition = 50%
/ hposition = values.targetcirclehpos
</shape>

<shape targetcircleinner>
/ shape = circle
/ size = (9%, 0.09px*display.canvaswidth)
/ color = white
/ vposition = 50%
/ hposition = values.targetcirclehpos
</shape>

<text correctmsg>
/ items = ("CORRECT")
/ color = green
/ position = (50%, 85%)
</text>

<text errormsg>
/ items = ("ERROR")
/ color = red
/ position = (50%, 85%)
</text>


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search