Preventing immediate response repetitions
 
 
 
PST User Forum
Home       Members    Calendar    Who's On
Welcome Guest ( Login | Register )
        



Preventing immediate response repetitions Expand / Collapse
Author
Message
Posted 3/26/2007 6:26:44 PM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 10/17/2007 12:04:54 PM
Posts: 10, Visits: 15
Hello,

I am designing an experiment in which subjects must press one of three response keys on each trial. However, I do not want them to be able to repeat responses across consecutive trials. For example, if the keys are labeled A, B, and C, I want to be able to program E-Prime such that if the subject presses key A on trial n, he is ONLY able to press either key B or key C on trial n+1. If he presses key B on trial n+1, then he is only able to press either key A or key C on trial n+2, and so on...

I already have my program set up such that E-Prime logs the response on each trial and that the only allowable response keys are A, B, and C. However, I do not know how to restrict the allowable responses on a trial-by-trial basis in the manner described above.

Any help would be greatly appreciated, given that a cursory search of the E-Prime support website did not turn up anything that seemed helpful. Thanks!
Post #274
Posted 3/28/2007 10:57:33 PM
Forum MVP

Forum MVPForum MVPForum MVPForum MVPForum MVPForum MVPForum MVPForum MVP

Group: Administrators
Last Login: 1/5/2009 9:26:59 AM
Posts: 576, Visits: 1,254
There are a number of ways to implement this and here is one of them...

1) Dim a string variable in User script.  Dim g_strLastResponse As String

2) Place an InLine as the last object in your procedure, with g_strLastResponse = Stimulus.RESP or whatever your Stimulus name is

3) Place an InLine as the first object in your procedure, use code similar to the following

If g_strLastResponse = "a" Then c.SetAttrib "Allowable", "bc"

If g_strLastResponse = "b" Then c.SetAttrib "Allowable", "ac"

If g_strLastResponse = "c" Then c.SetAttrib "Allowable", "ab"

4) In the Allowable field for your Duration/Input Stimulus, enter [Allowable]

-Brandon

Post #278
Posted 3/29/2007 10:27:03 AM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 10/17/2007 12:04:54 PM
Posts: 10, Visits: 15
Brandon,

Thank you very much for the clear and concise instructions. They worked perfectly--just what I wanted!
Post #282
« Prev Topic | Next Topic »


Permissions Expand / Collapse

All times are GMT -5:00, Time now is 6:19am

Powered By InstantForum.NET v4.1.4 © 2009
Execution: 0.109. 9 queries. Compression Disabled.