Thank you! I will try this out. I have a similar code and am now trying to define what would be a right  and a left response. We will see! Thanks! <br><br><div class="gmail_quote">On Fri, Nov 2, 2012 at 3:01 PM, terhi helminen <span dir="ltr"><<a href="mailto:helminenterhi@gmail.com" target="_blank">helminenterhi@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">
Hi,</p><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">

I have recently made a task where participant has to answer with joystick (pulling it backward or forward).  The Inline code below helped me to make an appropriate code, perhaps it helps you too... </p><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">


(from <a href="https://groups.google.com/forum/?fromgroups=#!searchin/e-prime/joystick$20as$20response$20device/e-prime/ww6C02LZ8nY/qDT5rsZrerkJ" target="_blank">https://groups.google.com/forum/?fromgroups=#!searchin/e-prime/joystick$20as$20response$20device/e-prime/ww6C02LZ8nY/qDT5rsZrerkJ</a> )</p>


<p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">----</p><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">


Dim nInitY As Integer<br>Dim nCurrentY As Integer<br>Dim nDiff As Integer</p><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">


nInitY = Joystick.CursorY</p><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">Do<br>   nCurrentY = Joystick.CursorY<br>
   nDiff = nInitY - nCurrentY</p><p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">Loop Until Abs(nDiff) > 50</p>
<p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">Stimulus.RTTime = Clock.Read<br>Stimulus.RT = Stimulus.RTTime - Stimulus.OnsetTime</p>


<p style="vertical-align:baseline;color:rgb(34,34,34);font-size:13px;font-family:Arial,Helvetica,sans-serif;margin:1em 0px;border:0px;padding:0px">If nDiff > 0 Then<br>   Stimulus.RESP = "Up"<br>
Else<br>   Stimulus.RESP = "Down"<br>End If</p></div><div>----</div><div>As I also wanted to give a feedback based on subjects answer, I used contingent branching based on the response. (See the example in <a href="http://www.pstnet.com/support/samples.asp?Mode=View&SampleID=3" target="_blank">http://www.pstnet.com/support/samples.asp?Mode=View&SampleID=3</a> ) </div>


<div><br></div><div>Hope this helps!</div><span class="HOEnZb"><font color="#888888"><div>- Terhi</div></font></span><div class="HOEnZb"><div class="h5"><br><br><div class="gmail_quote">On Thu, Nov 1, 2012 at 3:47 PM, Diana Laura Rosa Leyra <span dir="ltr"><<a href="mailto:dl.rosaleyra@gmail.com" target="_blank">dl.rosaleyra@gmail.com</a>></span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thanks Pip. I'll try this!<div><div><br><br><div class="gmail_quote">On Wed, Oct 31, 2012 at 7:46 PM, Pip <span dir="ltr"><<a href="mailto:pipgriffiths86@gmail.com" target="_blank">pipgriffiths86@gmail.com</a>></span> wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div>I'm not sure that you can do this automatically, but if you code some inline to store the final x co ord of the cursor then you can look at this in the output file and use filters to determine whether the correct answer was given. You can also set up a screen that will respond if the answer was "correct" through using this method. </div>



<div><br></div><div>Essentially you set a variable, get EPRime to write the x co ord to that variable and then get a conditional statement to read that file and feedback the necessary response to the participant </div><div>



<br></div><div>Hope this helped</div><div><br></div><div>Pip<br><br>Sent from my iPhone</div><div><div><div><br>On 31 Oct 2012, at 21:00, Diana Laura Rosa Leyra <<a href="mailto:dl.rosaleyra@gmail.com" target="_blank">dl.rosaleyra@gmail.com</a>> wrote:<br>



<br></div><blockquote type="cite"><div>All, <div><br></div><div>We would like to use a joystick as a response device. Our task requires participants to judge whether the hand they see on the screen is a right or left hand. We'd like for them to respond with the joystick. Basically, I am trying to define a correct answer in terms of the position of the joystick at the time of response. Anyone have any ideas on how this would work and if it would work at all? </div>



<div><br></div><div>I am working with EPrime 2.0 Professional and know that I have to use a bit of code, but am unsure as to where or how to use it. </div><div><br></div><div>Thank you, </div><div>Diana </div>

<p></p>

-- <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 <a href="mailto:e-prime@googlegroups.com" target="_blank">e-prime@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href="mailto:e-prime+unsubscribe@googlegroups.com" target="_blank">e-prime+unsubscribe@googlegroups.com</a>.<br>
To view this discussion on the web visit <a href="https://groups.google.com/d/msg/e-prime/-/1EHfBZClU6kJ" target="_blank">https://groups.google.com/d/msg/e-prime/-/1EHfBZClU6kJ</a>.<br>
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank">https://groups.google.com/groups/opt_out</a>.<br>
 <br>
 <br>
</div></blockquote></div></div></div><div><div>

<p></p>

-- <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 <a href="mailto:e-prime@googlegroups.com" target="_blank">e-prime@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href="mailto:e-prime%2Bunsubscribe@googlegroups.com" target="_blank">e-prime+unsubscribe@googlegroups.com</a>.<br>
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank">https://groups.google.com/groups/opt_out</a>.<br>
 <br>
 <br>
</div></div></blockquote></div><br><br clear="all"><div><br></div></div></div><span><font color="#888888">-- <br><div style="text-align:left"><span style="font-family:garamond,serif">-------------------------------<br>
Diana Laura Rosa-Leyra</span><span style="font-family:garamond,serif"></span><span style="font-family:garamond,serif"></span><br style="font-family:garamond,serif">
<span style="font-family:garamond,serif"><a href="mailto:dl.rosaleyra@gmail.com" target="_blank">dl.rosaleyra@gmail.com</a></span><br></div></font></span><div><div><br><br>

<p></p>

-- <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 <a href="mailto:e-prime@googlegroups.com" target="_blank">e-prime@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href="mailto:e-prime%2Bunsubscribe@googlegroups.com" target="_blank">e-prime+unsubscribe@googlegroups.com</a>.<br>
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank">https://groups.google.com/groups/opt_out</a>.<br>
 <br>
 <br>
</div></div></blockquote></div><br>

<p></p>

-- <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 <a href="mailto:e-prime@googlegroups.com" target="_blank">e-prime@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href="mailto:e-prime%2Bunsubscribe@googlegroups.com" target="_blank">e-prime+unsubscribe@googlegroups.com</a>.<br>
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank">https://groups.google.com/groups/opt_out</a>.<br>
 <br>
 <br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div style="text-align:left"><span style="font-family:garamond,serif">-------------------------------<br>Diana Laura Rosa-Leyra</span><span style="font-family:garamond,serif"></span><span style="font-family:garamond,serif"></span><br style="font-family:garamond,serif">
<span style="font-family:garamond,serif"><a href="mailto:dl.rosaleyra@gmail.com" target="_blank">dl.rosaleyra@gmail.com</a></span><br></div><br><br>

<p></p>

-- <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 <a href="https://groups.google.com/groups/opt_out">https://groups.google.com/groups/opt_out</a>.<br />
 <br />
 <br />