﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>Millisecond Forums » Millisecond Forums » Inquisit 4  » Script sometimes doesn't output last trial</title><generator>InstantForum 2017-1 Final</generator><description>Millisecond Forums</description><link>https://forums.millisecond.com/</link><webMaster>Millisecond Forums</webMaster><lastBuildDate>Mon, 22 Jun 2026 11:50:18 GMT</lastBuildDate><ttl>20</ttl><item><title>Script sometimes doesn't output last trial</title><link>https://forums.millisecond.com/Topic13153.aspx</link><description>Hi Everyone,&lt;div&gt;&lt;div&gt;&lt;br/&gt;&lt;/div&gt;I'm trying to add a simple open ended question at the end of the already existing Flanker Task script I downloaded online. I added this as a block (called &lt;strong&gt;block.donate_intro&lt;/strong&gt;) with 1 trial composed of an "openended" question. However, sometimes when I run the script the instruction page appears, but the open ended question doesn't. It doesn't even appear on the output. Other times, however, it runs perfectly.&lt;div&gt;&lt;br/&gt;&lt;/div&gt;&lt;div&gt;Am I adding this in the incorrect way? Why is it not working every time?&lt;div&gt;&lt;div&gt;&lt;br/&gt;&lt;/div&gt;Attached is my entire script. I hope someone can help!&amp;nbsp;&lt;div&gt;&lt;div&gt;&lt;br/&gt;&lt;/div&gt;Thanks!&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description><pubDate>Tue, 29 Apr 2014 13:54:56 GMT</pubDate><dc:creator>Psych.Lab</dc:creator></item><item><title>RE: Script sometimes doesn't output last trial</title><link>https://forums.millisecond.com/Topic13154.aspx</link><description>The block you added runs one &amp;lt;trial&amp;gt; element, which displays the "instructions":&lt;div&gt;&lt;br/&gt;&lt;/div&gt;&amp;lt;block donate_intro&amp;gt;&lt;br/&gt;&lt;strong&gt;/trials = [1 = instruct1]&lt;/strong&gt;&lt;br/&gt;&amp;lt;/block&amp;gt;&lt;div&gt;&lt;br/&gt;&lt;/div&gt;That &amp;lt;trial&amp;gt; then either does or does not invoke the &amp;lt;openended&amp;gt; element via /branch depending on the response:&lt;div&gt;&lt;br/&gt;&lt;/div&gt;&amp;lt;trial instruct1&amp;gt;&lt;br/&gt;/stimulusframes = [1 = instruction1]&lt;br/&gt;/validresponse = (28, 50, 46)&lt;br/&gt;&lt;strong&gt;/branch = [if (trial.instruct1.response == 50) openended.donate]&lt;/strong&gt;&lt;div&gt;[...]&lt;/div&gt;&lt;div&gt;&amp;lt;/trial&amp;gt;&lt;br/&gt;&lt;/div&gt;</description><pubDate>Tue, 29 Apr 2014 13:54:56 GMT</pubDate><dc:creator>Dave</dc:creator></item></channel></rss>