Generating a performance summary at task completion?
liwenna
liwenna at gmail.com
Sun Aug 9 21:33:45 UTC 2009
Hey Morgan,
I spotted at least 1 typo allready...
dim omitedcounter as integer -> dim omitTedcounter as integer
there's bound to be more of those... >.>
On Aug 9, 7:20 pm, Morgan J Prust <morgan.pr... at gmail.com> wrote:
> Liwenna,
>
> Thanks so much for this thoughtful and extensive reply! I'll give it a shot
> and let you know.
>
> Thanks again,
>
> Morgan
>
> On Sat, Aug 8, 2009 at 8:12 AM, liwenna <liwe... at gmail.com> wrote:
>
> > Hey Morgan,
>
> > Basically what you need are variables that run accros the whole
> > experiment instead of per trial. You can define these in the user tab
> > of the script window. After you've generated the script a script
> > window is opened that has two tabs to be chosen from in the bottom of
> > that window: full (shows the script) and user (which is empty). Now
> > declare the variables you need in that user-tab. For instance:
>
> > ========================
> > dim correctcounter as integer
> > dim errorcounter as integer
> > dim rtcorrectcounter as integer
> > dim rterrorcounter as integer
> > dim omitedcounter as integer
> > dim trialcounter
>
> > dim finalpercentcorrect as integer
> > dim finalpercenterror as integer
> > dim finalpercentomitted as integer
> > dim meancorrectrt as integer
> > dim meanerrorrt as integer
> > ==========================
>
> > Now at the end of a trial (or after an answer is given) you need to
> > insert an inline that updates the error- an correctcounter based on
> > the answer given.
> > The following code should do this: firstly it simply updates the
> > counter that keeps the total number of trials which we'll need later
> > on. Then it determines whether or not a response is given. If there is
> > no response (slidedisplay.resp = "") then the omittedcounter is
> > updated and written to the edatfile. If a response is given (case
> > else) it goes on to determine whether or not this response is correct
> > and based on that, it updates either the correct- or the errcounters
> > and writes them to the edatfile. The z in front of the attributenames
> > makes them all appear at the far right of the edat file (which is
> > alphabetically ordered) so you can easily find them. This select case-
> > construction is to make it so that omitted trials are not counted as
> > errortrials.
>
> > ==========================
> > trialcounter = trialcounter + 1
>
> > Select case slidedisplay.resp
>
> > case ""
> > omittedcounter = omittedcounter + 1
> > c.setattrib "zomittedcounter", omittedcounter
>
> > case else
> > if slidedisplay.acc = 1 then
>
> > correctcounter = correctcounter +1
> > c.setattrib "zcorrectcounter", correctounter
> > rtcorrectcounter = rtcorrectcounter + slidedisplay.rt
> > c.setattrib "zrtcorrectcounter", rtcorrectcoutner
>
> > end if
>
> > if slidedisplay.acc = 0 then
>
> > errorcounter = errorcounter + 1
> > c.setattrib "zerrorcounter", errorcounter
> > rterrorcounter = rterrorcounter + slidedisplay.rt
> > c.setattrib "zrterrorcounter", rterrorcounter
>
> > end if
>
> > end select
>
> > =======================
> > The above script updates the counters for each trial based on the
> > answer given. At the end of the experiment we should of course make
> > the counters go to percentages and the rt's should be averaged.
>
> > Place something like this in an inline that is located on the
> > sessionproc after (all) the trialproc(s) have been run (I'm not
> > entirely sure whether the / for dividing will work just like that...
> > but you should be able to work that out). Firstly it updates the user-
> > tab variables based on the counters and the second part writes it all
> > to the edat file.
>
> > =============================
> > finalpercentcorrect = correctcounter / trialcounter
> > finalpercenterror = erorrounter / trialcounter
> > finalpercentomitted = omittedcounter / trialcounter
> > meancorrectrt = rtcorrectcounter / correctcounter
> > meanerrorrt = rterrorcounter / errorcounter
>
> > c.setattrib "zfinalpercentcorrect", finalpercentcorrect
> > c.setattrib "zfinalpercenterror", finalpercenterror
> > c.setattrib "zfinalpercentomitted", finalpercentomitted
> > c.setattrib "zmeancorrectrt", meancorrectrt
> > c.setattrib "zmeanerrorrt", meanerrorrt
>
> > ==========================
>
> > Lastly you can show a slide that tells the subject the following
> > (place a text like this in a text-object).
>
> > ==========================
> > You've finished [trialcounter] trials and of these trials you've
> > answered [finalpercentcorrect] % correctly, [finalprcenterror]%
> > incorrectly and you did not answer [finalpercentomitted]% of the
> > trials. Your average reactiontime on the trials you've answered
> > correctly was [meancorrectrt] milliseconds, and for the trials you've
> > answered incorrectly your average reactiontime was [meanerrorrt].
> > ==========================
>
> > Ok.... now all the above is to give you an idea of what should be done
> > more or less.... I did it top of my head and have no opportunity to
> > actually run it in e-prime so I am not entirely sure whether it will
> > all work as intended but it should get you started.
>
> > Good luck on it!
>
> > liwenna
>
> > On Aug 7, 7:39 pm, Morgan <morgan.pr... at gmail.com> wrote:
> > > I'm attempting to program an n-back task in E-Prime and am currently
> > > trying to figure out how to have the task generate a performance
> > > summary to be displayed at the completion of the task, which would
> > > include % of correct responses, % of incorrect responses, reaction for
> > > correct responses, reaction for incorrect responses, and the number of
> > > omitted trials across the entire task (in other words, not after each
> > > trial or each block, but at the end of all of the trials/blocks).
> > > Would any of you know how to do this?
>
> > > Many thanks,
>
> > > Morgan Prust
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---
More information about the Eprime
mailing list