feedback contingent on response time
Tracy Lennertz
lennertz.t at gmail.com
Tue Oct 7 16:09:10 UTC 2008
On Oct 7, 2008, at 11:45 AM, David McFarlane wrote:
>
> Tracy,
>
> Thank you for including all the necessary script excerpts, I like
> that a lot better than having to wade through a complete attached
> program.
>
> Well, I have a lot to say about this, mostly about programming style,
> since in fact I do not see why your script does not work. But I will
> propose a solution in the end.
>
>
> First, since the OverallRT appears in your E-DataAid file, I assume
> that you have verified that it does indeed go above 1500 ms in your
> debugging runs. Otherwise I would be concerned lest your progam
> simply does not allow responses past 1500 ms. Also, note that
> without a response you will get a RT of 0, and this will bring the
> average down, so you might want to make sure to take care of that
> (unless you just left that out of your excerpts), something like
>
> If Stimuls5.RT > 0 Then ' got a response
> OverallRT.AddObservation Stimulus5.RT
> Else ' no response
> OverallRT.AddObservation <maximum possible RT>
> End If
>
>
> Second, look closely at your If... Then... ElseIf cascade, and see
> what happens if OverallRT exactly equals 1500, or OverallACC exactly
> equals 80. Your If ... Then does not cover those cases, and in that
> case your script does nothing. Did you mean to do that? If not,
> then somewhere in there you should have some "<=" or ">=" instead of
> "<" or ">". Also, good practice dictates that you have a final Else
> clause even if your program should never get there (I call this a
> "sanity check"), we call practices like this "defensive programming"
> (look that up on Wikipedia).
>
>
> Third, if it were me, instead of modifying object text directly, as in
>
> BlockACC.Text = "Your average accuracy is " & ...
>
> I would use an attribute reference, as in
>
> c.SetAttrib "BlockACC", "Your average accuracy is " & ...
>
> At the very least, an attribute reference in the object alerts the
> programmer that this value will be modified at run time, otherwise
> the programmer has no clue that text will be modified in script. But
> this may come down to a matter of personal programming style.
>
>
> Fourth, I note that your message always starts with
> "Your average accuracy is " & c.GetAttrib("OverallACC") & " % and
> your responses are "
> I would take advantage of that in clarifying the script with a
> rewrite.
>
>
> Fifth, I would say that, unless this is meant just as an
> instructional program, your program is over commented. Things like
> the .AddObservation method and Debug.Print should be general
> background knowledge for anyone using E-Prime, and do not need to be
> explained in program comments, that just makes the program harder to
> read. Comments should be reserved to answer *specific* questions
> that may occur to others reading the script.
>
>
> So much for my unsolicited $.02. Now, if it were me, I might use an
> attribute reference for the text in BlockACC (e.g., [BlockACC]), and
> completely rewrite your If... Then script. Let's assume that RT =
> 1500 is still fast, and ACC = 80 is still good, then the script might
> come out like this:
>
> Dim blockACC as String ' just for convenience
>
> ' Message always starts the same:
> blockACC = "Your average accuracy is " & c.GetAttrib("OverallACC") _
> & " % and your responses are "
> If c.GetAttrib("OverallRT") <= 1500 Then ' fast RT
> blockACC = blockACC & "fast." ' all done if good ACC
> If c.GetAttrib("OverallACC") < 80 Then ' poor ACC
> blockACC = blockAcc & " Please try harder."
> End If
> Else ' slow RT
> blockACC = blockACC & "slow."
> If c.GetAttrib("OverallACC") < 80 Then ' poor ACC
> blockACC = " Please try harder."
> Else ' good ACC
> blockACC = blockACC & " Good Job and please respond quickly."
> End If
> End If
> c.SetAttrib "BlockACC", blockACC
>
>
> No doubt with a little thought you can improve even further on this.
> -- David McFarlane, Professional Faultfinder
>
>
> >
-----------------------------------
Tracy Lennertz
Department of Psychology
Northeastern University
125 Nightingale Hall
360 Huntington Avenue
Boston, MA 02115
617.373.4141
lennertz.t at neu.edu
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "E-Prime" group.
To post to this group, send email to e-prime at googlegroups.com
To unsubscribe from this group, send email to e-prime+unsubscribe at googlegroups.com
For more options, visit this group at http://groups.google.com/group/e-prime?hl=en
-~----------~----~----~----~------~----~------~--~---
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listserv.linguistlist.org/pipermail/eprime/attachments/20081007/5512d184/attachment.htm>
More information about the Eprime
mailing list