ianhussey / ImplicitAssociationTest

Implicit Association Test (IAT) programmed in PsychoPy [no longer maintained]
GNU General Public License v3.0
23 stars 13 forks source link

Open Source Implicit Association Test

Written in PsychoPy, but more flexible than the version bundled with it.

PLEASE NOTE THAT I NO LONGER MAINTAIN THIS CODE. AS PSYCHOPY HAS BEEN UPDATED OVER TIME, IT MAY HAVE BROKEN FEATURES. FEEL FREE TO FORK, FIX AND MAINTAIN THIS CODE IF YOU WISH.

[TOC]

License

Ian Hussey 2016 (ian.hussey@ugent.be) GPLv3+

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

Version

1.2.1 (2016/04/16)

Description & purpose

The IAT is an implicit measure of automatic behaviour or automatic biases (Greenwald, Nosek & Banaji, 1998). This implimentation of the IAT has high fidelity to the procedure described in Nosek et al. (2007: the IAT at 7), and to the standard IAT Inquisit script provided by Millisecond. See block layout below. IMHO, fidelity is higher than other freely available alternatives, such as the FreeIAT or OpenIAT (e.g., the latter has a different block layout, and also uses a combination of free responding and accuracy feedback, where the IAT almost invariably uses one or the other but not both).

Requirements

Usage

Block layout

The current version follows the block layout described in Nosek et al. (2007: the IAT at age 7). The contents of each screen follows the standard Inquisit IAT distribution very closely. However, the Inquisit IAT uses the older block layout of 20 trials in block 5.

Localisation and customisation

All stimuli and instructions within the task are set via the stimuli.xlsx and task.xlsx files.

PsychoPy has Unicode support, so translating the task into other languages (Spanish, Polish, Japanese, etc.) only requires changes to these excel files.

Output

Data files

.psydat, .csv and .log files are produced for each participant. The .csv file alone is sufficient to most analyses (e.g., calculation of D scores). To my understanding, the format of the .csv output files are Tidy Data compliant (Wickham, 2014) and therefore easy to analyse (e.g., in R) with little to no processing needed.

Data processing

The included processing.rmd R script produces accuracy and latency summary data and D1 scores for each participant (including "overall" D1 scores, D1 scores for each trial-type, and split-half overall D1 scores).

Very little familiarity with R/RStudio is needed to use this script.

  1. Open the script in RStudio.
  2. Click "Knit", this will run the script, save the processed output, and create a html file record.

Interpretation of D1 scores

Positive D1 scores refer to faster responding on the block where response mappings are shared between trial types 1 & 3 and 2 & 4 (e.g., flowers-positive/insects-negative) than the block where response mappings are shared between trial types 1 & 4 and 2 & 3 (e.g., flowers-negative/insects-positive).

Known issues

  1. If participants get 100% of trials correct throughout the whole task then three incorrect response columns will not be created for that participant. This is highly unlikely, and futhermore is not a problem if your data processing workflow merges data files across participants based on column header names (e.g., with R using readr's read.csv) rather than column positions (e.g., a SPSS script using a GET command, or some other R commands which assume equivalent table shapes).
  2. Block order is not recorded in the data file, but is derived from the participant code (odd number vs even number).
  3. “Empty” cells in the instructions file must actually include a whitespace character or task will crash. If text stimuli are used, put “blank.png” in the image stimulus box.
  4. Requires 5 exemplars per category, as the stimuli file conflates block structure with exemplars to be used. I have a method to change this, but haven't implimented it yet.
  5. Stimuli presentations are based on timing rather than screen frames. This is relatively easy to alter, but requires more from the user in terms of setting the script up with their specific hardware. Marginal timing accuracy trade off.

Timing accuracy

PsychoPy is technically capable of millosecond timing, depending on design choices by the researcher (see Garaizar & Vadillo, 2014).

The current implementation is written to be at least as accurate as other implementations of the IRAP (i.e., accurate to within a frame or c.17ms). The stimuli to be presented within a block are generated on the pre-block rule screen, and then pop()'d on each trial.

If you're looking for higher accuracy (e.g., for EEG/fMRI work) you'll want to change all timings to frames rather than seconds. You may also want to remove the presentation of images if you're not using them.

Issues

If you have any issues, find bugs, or observe any unwanted divergences from other implementations please report them using GitHub's issue reporting system. Doing it online rather than by emailing me allows other people to benefit from your experience.

If there are additional features or refinements you would like to see please feel free to contribute to the project yourself by branching, editing, and submitting a pull request on Github. You can also email me at ian.hussey@ugent.be.

To do

Changelog

1.2.1

1.2

1.1

1.0.1

R script updated.

1.0

Used in a completed experiment and bug tested. No changes made relative from 0.10, which I've upgraded to a release copy.

0.10

Added new code components so that only a single stimulus file and single blocks file is needed. The contents the category labels and the correct and incorrect responses are determined before each trial based on the trial type, block order and current block. This limits the scope for human error when putting together the stimuli files.

0.9.3

0.9.2

0.9.1