view README @ 7:e2242b4b0b3d

Allow instructions file to be passed as a command line argument. Ignore-this: 60e440775e698898e485f8f0dfbd3db
author Marcus Pearce <m.pearce@gold.ac.uk>
date Fri, 15 Jul 2011 16:36:53 +0100
parents ac0d14c9c9ab
children 235484b93707
line wrap: on
line source
AUTHOR

Marcus Pearce <m.pearce@gold.ac.uk>


USAGE 

  java Experiment <show clock?> <multiple> <n> <midi device> <scale length> <low anchor> <high anchor> <midi file directory> <instructions file>

where <show clock?> specifies whether to show the clock (0 = no; 1 =
yes) and <multiple> and <n> are integers: the clock runs for <n> time
units before a probed event where the time unit is a multiple of the
tatum as specified by <multiple>.

<midi device> is an integer specifying the midi device to use (usually 0).

<scale length> is the number of levels of the rating scale and <low
anchor> and <high anchor> are its high and low anchors respectively
(e.g., "highly unexpected", "highly expected" with a scale length of
7). 

<midi file directory> is the directory where the midi files are stored

<instructions file> is an html file containing the instructions for
the participant which will be displayed at the beginning of the
experiment.

See runExperiment.bat for an example.

To use in a study:

1. put the relevant midi files in the directory specified by <midi
file directory> (e.g., Data/Midi/)

2. edit pfilelist.txt and filelist.txt (also in <midi file directory>)
to contain the midi files played in the practice and main blocks
respectively: put one file on each line followed by a list of note
numbers to probe with the visual clock. NB: that the last line of
these files must terminate with a newline.

3. edit Data/instructions.html if necessary or create a new set of
instructions.

The results are written to files in the Results/ directory.

4. responses can be given either using the mouse or using the numeric
keys (except in the case of a scalelength of 2 where the keys 'q' and
'p' are used).

FILES AND DIRECTORIES: 

Data/: 
  - instructions.html: the default instructions file 
  - pfilelist.txt: the list of midi filenames in the practice block 
  - filelist.txt: the list of midi filenames in the main block 
  - Midi/: the location of the midi files specified above

Results/: 
  - the results are written to files in this directory 

Icons/: 
  - contains icons used for the GUI


DEVELOPMENT 

The code is organised according to a MVC structure: 

Model:      Experiment.java 
             - FileList.java           
             - ProbeID.java
             - MidiPlayer.java
             - MelodyResults.java   
             - SubjectResults.java
             - Block.java 

View:       ExperimentGui.java 
             - Clock.java
             - InstructionsPanel.java
             - StimulusPanel.java
             - SubjectDataPanel.java
             - InterBlockPanel.java

Controller: ExperimentController.java