rerun all trials when error

Colleen Parks cmparks at ucdavis.edu
Fri Oct 29 15:39:27 UTC 2004


Anna,
I don't know about that code (although I *think* it should be "PickList1.Run c"), but here's something that worked for me.  I needed to train subjects to a 50% criterion and their accuracy was logged in the tag of a feedback object (feedback.tag).  "trainCB" is the highest level list object that the trial level procedure was called by. (Note that I have "Set AccuracyMonitor = New Summation" in there twice, but I can't remember why I had it like that.  Doesn't seem like it should be necessary, but it did what I needed it to do.)  I would think something similar would work for you if you just modify the criterion and the if...then statements for what you need.
Hope this helps,
Colleen

User script:

Dim AccuracyMonitor As Summation
Dim TrialCount as Integer

In an inline object on the Session Proc before the relevant list and procedure:

Set AccuracyMonitor = New Summation
TrialCount = 0

On the relevant trial-level procedure, at the end:

TrialCount = TrialCount + 1

Set AccuracyMonitor = New Summation  

AccuracyMonitor.AddObservation c.GetAttrib("feedback.Tag")

If TrialCount = 44 Then

     If AccuracyMonitor.Mean >= .5 Then

              trainCB.Terminate
     Else
  
              TrialCount = 0
              AccuracyMonitor.Reset

             trainCB.Load
              Set trainCB.TerminateCondition = Cycles(44)

          End if           
End if



---------------------------------------
Colleen Parks, Ph.D.
University of California
One Shields Ave.
Davis, CA 95616

cmparks at ucdavis.edu
530.754.9439
----- Original Message ----- 
  From: Anna Holmes 
  To: eprime at mail.talkbank.org 
  Sent: Thursday, October 28, 2004 11:10 PM
  Subject: rerun all trials when error


  Hello,
  Please, please can anyone help me?
  I need to be able to rerun a practice until a participant reaches 100% accuracy. I have tried to copy and modify the criterion based exit sample to no avail (see below). I assume a Do...Loop command but don't know how to do this. Can anyone help me out?
  User:
   

  'Declare Summation object

   Dim Accuracy as Summation

   

  'Declare variable to check criterion

  Dim CriterionMet as Boolean

   

  Inline:

   

  Name: InitVar (beginning of session proc)

  'Initialize variables

  Set Accuracy = New Summation

  TrialCount = 0

  CriterionMet = True

   

  Name: AddAcc (end of trial proc)

  'Add individual accuracy scores to Summation object

  Accuracy.AddObservation CDbl (c.GetAttrib("Stimulus.ACC"))

   

  Name: CheckAcc (end of block (PickList1) proc)

  'Evaluate accuracy

  If Accuracy.Mean < 1.0 Then

              PickList1.Run (one of the errors thus far reads invalid context)

  Else

              '100% acc acheived

              GoTo Label1

  End If



  Thanks

  A

  -----------------------------------------------------------------------
  Anna D Holmes. BSpPath(Hons)
  Division of Speech Pathology
  School of Health and Rehabilitation Sciences
  University of Queensland 
  QLD 4072 Australia
  Phone: +61 7 3346 9726
  Fax: +61 7 3365 1877
  a.holmes at uq.edu.au
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listserv.linguistlist.org/pipermail/eprime/attachments/20041029/e5eac3c9/attachment.htm>


More information about the Eprime mailing list