restriction of scriptingRT

We checked whether scriptingRT can be used to run studies that want to distinguish between more than 2 answers with a keyboard. Unfortunately, that is not the case. So, you can program a Stroop task where people have to distinguish between two colors, and press one of two keys. However, you cannot program a Stroop task where people have to distinguish between four colors, and press one of four keys. More precisely, you can, but the protocol cannot list the actual responses, only whether the answer was positive or negative, which are only two categories.

This comes out of our starting point, DMDX, where the behavior is the similar.

We can certainly change this at some point, and allow saving the actual response in the protocol, but it depends on having programming ressources to do so. For the time being, this is a restriction.


passing info to scriptingrt

when embedding a scriptingrt swf in a web page, it is possible to pass information from the html page to the flash swf in the form of flashvars (see Flashvars on the examples page).

however, we noticed some problems when embedding a swf in a qualtrics page – the swf seemed to loose focus, or at least it was sometimes hard to give the focus back to it after clicking somewhere else. As an alternative, we decided to test opening the swf in a separate window directly, without embedding it in a html wrapper. Question is, can you then still transfer info to it?

Turns out you can. This swf displays 4 trials. Two of them are taken from flashvars, and we pass them here appended after the file name in the link, with “…flashvars.swf?myFirstName=thomas&myLastName=schubert” target=”_blank” (opening in a new window). If you change those values, you get different trials.

counterbalancing in scriptingRT, and new version 0352

here is a demo how to counterbalance block order in scriptingRT.

in this example, there are two blocks of items, one instruction in the beginning, and one break between the blocks.

branching is used to influence the order of blocks. I leave the next attributes initially empty, and then fill them depending on the random number.

to do this, I had to add a new property that can be accessed by the branching operations, namely This brings us to a new version of scriptingRT0352.swc

this demonstrates the power of changing attributes at runtime. you can do this to everything that has an id. I also show this here by changing the feedbacktext.text to give feedback of overall performance in the break.


new version of the source was uploaded to github


how to build scriptingrt from the source code

ScriptingRT is open source, and there might come a day when you want to add or change it. If you do that, you have to compile the source code again into the library. Here is how you do that using FlashBuilder.

In FlashBuilder, create a new Flex Library Project.

Move the org folder from the downloaded source code and everything in it to the source folder of your new project. Usually, the source folder will be called src, so you will have a folder structure MyScriptingProject/src/org/nad/… . Make sure that you do not create something like src/src/org when you copy the source code folders.

ScriptingRT uses two additional libraries that you need to include when compiling.

1. The D.Eval Library

Download the zip file containing the library, extract the swc file (currently D-eval-1.1.swc), and put it in a convenient folder (not the project folder itself)

Link to that file in Flashbuilder via Project/Properties/Flex Library Build Path, where you click Add SWC and point it to the .swc file of that you just unpacked.

When you are finished with this, the .swc file should be listed as a Referenced Library in your Package Explorer view.

2. The AS3Eval library

Download their source code zip, unpack.

You need three files from the com/hurlant/eval/ast folder:,, and Importantly, you need to keep that folder structure. In your src folder, create subfolders hurlant/eval/ast/, and put the three files there. They will show up in your Package Explorer.

Your project should look similar to this:


If everything worked, you should have no errors in the problems console, and be able to build the scriptingrtxxx.swc library

More on linking ressources in FlashBuilder


thanks to Tyler Burleigh, we have a new version of the scriptingRT library, scriptingRT0351.swc. This update fixes the bug that the first feedback always appeared in the wrong location with the wrong feedback. We also have a small correction to the php file that stores the results, which now formats the output better.

I realized that I never put a good description out on how to compile the source code. I will add this soon in a post and on github.

Slides from SPSP talks

I talked about ScriptingRT and measuring response latencies with Arduinos at this year’s SPSP. Here are the slides. Talk on Arduino in the Embodiment precon and  talk on ScriptingRT at the conference.

Another talk at the symposium was Winter Mason on the open source HTML5 IAT. His slides.

Talk number 3 from the symposium was from Robert Wilson on the use of smartphones – combining audio and experience sampling. Check out the slides.

server for saving data

in the past, we used the server for saving data from scriptingRT. That server is not maintained by myself, and has been down for several days now. At the moment, I unfortunately cannot resurrect it.

Several people have become adept at simply setting up their own servers for saving data, so this is what I recommend from now on:

Download the php script, put it on your own server, and point your ScriptingRT files to it. This way, the files will be saved on your own server, where you can take care of them.

If you need to use our server, please let me know.