Demo Scripts

Intermediate Demos

logtrial in practice

logtrial in practice

Demo how to use the logtrial() function in a typical reaction time experiment.

Sum Demo

Sum Demo

Show how to write and use a function that sums some values in an array.

Image Demo Keep Constant Height

Image Demo Keep Constant Height

Show image in a block with height at 100% of the block's height, with variable width. Suitable for showing images of printed words of varying width.

Scoring Demo

Scoring Demo


Score Word Responses

Score Word Responses

Function to help you score free recall answers as obtained with the largeinput() function

logtrial demo

logtrial demo


Digit Span Task

Digit Span Task

This is a fairly typical implementation of the digit span forward task, similar to what one might encounter in a neuropsychological test battery. The task takes less than 5 min and can be done on a PC with a mouse or on a large touchscreen (tablet or large mobile phone). The digit span is reported at the end of the task.

Lexical Decision Task

Lexical Decision Task

Fairly complete implementation of a typical lexical decision task, which takes about 6 min. It is suitable for use in lectures, where the audience can do the task on a laptop (keyboard). Because keyboard responses are required, the task cannot be taken on a mobile phone. Mean reaction times to words and nonwords are reported at the end with total correct responses. Individual subjects can also download their own data in a format that can be imported into a spreadsheet, like Excel or Google Sheets.

Go/No-Go Task

Go/No-Go Task

This is a fairly typical implementation of the Go/No-Go Task, which takes about 2.5 min. It is suitable for use in lectures, where the audience can take the test on a laptop (keyboard) or mobile phone (touch screen). Feedback is given (including d-prime based on Hits and False Alarms).

Basic 1-Back Task

Basic 1-Back Task

Brief demo of a 1-Back Task to get a feeling for how this task is often implemented. Stimuli are digits 1, 2, and 3 and order is fully random (and may differ per subject). Feedback is given at the end. Runs with keyboard, mouse, and touch screen.

Use of closesession()

Use of closesession()


Script 8.11. Simple bug catching game

Script 8.11. Simple bug catching game


Pong

Pong