your last option, though a little messy, is the only way to go, i think.<br><br>>>- have the stimulus terminate upon response and go to the logging<br>
script, then reappear for the remainder of the unused time, and same<br>
for the blank screen afterward. I am attempting this solution, but it<br>
is quite messy and round-about because the response may occur during<br>
the stimulus presentation or during a blank screen.<br><br>here's how i would consider doing it:<br>first, plan to have the SlideObject, or whatever is presenting your stim have a Duration of 0, but a response window as long as you'd like to be collecting responses.<br>
set up a variable to record the time (Clock.Read) in an Inline immediately preceding your SlideObject with 0 ms duration.<br>then in an Inline immediately following your SlideObject, have a loop. something like this:<br>
Do<br> If SlideObject.RT>0 And NotYetSignaledMatlab=TRUE Then<br> send your event code to matlab<br> NotYetSignaledMatlab=FALSE<br> End If<br>Loop Until (Clock.Read - yourTimeVariable) > yourStimDuration<br>
clear the screen then<br>Do<br>Loop Until (Clock.Read - yourTimeVariable) > (yourStimDuration + yourBlankScreenDuration)<br><br>hope that helps.<br><br>ben<br><br><div class="gmail_quote">On Tue, Mar 24, 2009 at 2:36 PM, Emz <span dir="ltr"><<a href="mailto:emzcoffey@gmail.com">emzcoffey@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
Dear E-Prime people,<br>
<br>
I would like to know if E-Prime has some capability to run a script at<br>
any time during a task upon button press without interrupting its user-<br>
end activities.<br>
<br>
The problem in more detail is as follows:<br>
<br>
I am using a variant of the N-back task and would like to precisely<br>
log when the user presses one of the two response buttons. I know this<br>
is easy to do using E-Prime's logging functions; however, I am<br>
exporting data in real time to a MatLab matrix in another computer<br>
which is necessary for my experimental set-up. The data transfer is<br>
accomplished through a few lines of script, which I have inserted in<br>
appropriate places in the E-Prime code to mark events of interest.<br>
This works nicely, except for subject responses since the stimulus<br>
needs to be shown for a fixed length of time.<br>
<br>
I have considered a few possible solutions, but none seem very good:<br>
- have the stimulus terminate upon response and go to the logging<br>
script; however, this affects the task in undesirable ways<br>
- use script to collect and output the E-Prime reaction time, correct<br>
response info, etc. after the trial finishes. This means the reaction<br>
time data will be desynchronized with the rest of the data file and<br>
will require additional calculations to identify where in the data<br>
file the button press took place. I am concerned this will introduce<br>
error as there are already several data files with different sampling<br>
rates to be aligned post-experiment.<br>
- have the stimulus terminate upon response and go to the logging<br>
script, then reappear for the remainder of the unused time, and same<br>
for the blank screen afterward. I am attempting this solution, but it<br>
is quite messy and round-about because the response may occur during<br>
the stimulus presentation or during a blank screen.<br>
<br>
Ideally, I would just need a way to execute the send script during the<br>
stimulus presentation when the subject responds, without terminating<br>
the activity. Any ideas if this is even possible?<br>
<br>
Pointers / help function references, etc. all welcome,<br>
<br>
<br>
EC<br>
<br>
<br>
<br>
</blockquote></div><br>
<br>
--~--~---------~--~----~------------~-------~--~----~<br>
You received this message because you are subscribed to the Google Groups "E-Prime" group. <br> To post to this group, send email to e-prime@googlegroups.com <br> To unsubscribe from this group, send email to e-prime+unsubscribe@googlegroups.com <br> For more options, visit this group at http://groups.google.com/group/e-prime?hl=en<br>
-~----------~----~----~----~------~----~------~--~---<br>
<br>