Terminating 1 procedure in a List
Tony Zuccolotto
anthony.zuccolotto at pstnet.com
Wed Jun 5 13:30:52 UTC 2002
David,
I think the easiest way to do this is to check at the beginning of the
trial if the current trial type is allowed and then exit the procedure
without running if it not, e.g. keep an attribute that indicates the
trial type (which presumably you already have) and also keep a global
array or string of the trial types you want to allow (if you use a
string check out the Item$() function in E-Basic Help to help you rip
through the string w/o having to write your own parsing code).
If the trial type is not allowed then just call Exit Sub. In the
following example I assume the existence of a Function that checks a
condition against a list of valid conditions and returns True or False
if the trial condition is allowed.
If Not IsTrialTypeAllowed( c.GetAttrib("TrialType") ) Then
Exit Sub
End If
This will cause the list to sample again, but because you never allow
the procedure to end you will not get anything logged in the data file,
e.g. it is as if the trial did not exist. The only downside to this is
a small potential increase in your inter-trial-interval. If you need to
control for that you should be able to use the cumulative timing mode
and prerelease features on the last object in the trial to make this
more consistent.
Regards,
Tony
*** DISCLAIMER: VIEWS EXPRESSED ARE MY OWN AND DO NOT NECESSARILY
REFLECT THOSE OF MY EMPLOYER ***
Anthony P. Zuccolotto
Vice President of Operations
Psychology Software Tools, Inc.
2050 Ardmore Boulevard
Suite 200
Pittsburgh, PA 15221-4610
Phone 412-271-5040
FAX 412-271-7077
Email anthony.zuccolotto at pstnet.com
Internet http://www.pstnet.com/
> -----Original Message-----
> From: David Hairston [mailto:dhair at wfubmc.edu]
> Sent: Monday, June 03, 2002 12:09 AM
> To: eprime at mail.talkbank.org
> Subject: Terminating 1 procedure in a List
>
>
> I am designing an experiment in which it will be necessary to
> "permanently" terminate (i.e., no more sampling) individual
> Procedures within the same List as some criterion is met.
> For example, assume 4 procedures, A, B, C, and D. When X
> incorrect responses occur during Proc A, B-D continue, until
> the same occurs for each independently. Any suggestions as
> to how to do this?
>
> I have attemped using script to use the SetWeight method on
> the Factor object to reset the weight of the current
> procedure to 0, effectively removing it from the list. This
> is done in an Inline at the end of each procedure, if that
> matters. This *seems* to work, except that 1.) it takes 1
> more sample before dropping out, and more crucially 2.) when
> all procedure weights are set to 0 (i.e., after last one hits
> criterion) E-Prime crashes and I get a lovely Windows error
> saying that an illegal operation has been performed....
> ...I'm guessing this is because its going back for another
> sample and discovers it can't because there are none.
> Anybody have a suggestion on how to do this, or why it is
> looking to take 1 more sample after (theoretically) the
> weight has been set to 0?
>
> Thanks,
> Dave
>
>
More information about the Eprime
mailing list