Tik-76.115 Individual Project: Guinea Pig
$Id: SASconverter.html,v 1.5 1996/04/22 19:03:04 jrintafi Exp $

Results Processing - SAS Converter

General overview

Results created by the Guinea Pig system are in a format different from what the SAS statistical sofware package expects. We will create a small converter program to convert result data into SAS format.

File formats

The Guinea Pig project will create a results file for all the persons taking the test. This file contains different tagged data items.

The SAS statistical package expects all rows of the input file has the same format. Each column is separated by a tabulator and a new line indicates the starting of a new input row.

gpResProc - program for converting result files

The gpResProc program of the Results Processing module is the program that converts the results.raw files for the SAS, Excell or any other analyzing program that can read tabulated data.

Starting the Program

First go to the test directory where the configuration files etc. are. Then you can type:
    gpResProc
assuming that your test configuration file's name is 'test.config'. If it isn't, use the '-f' option to specify the file's name like this:
    gpResProc -f alt_test.config

Next the program will search for guineapig subdirectories for converting the results. It scans the GuineaPigs directory for directories that have the right kind of name and which contain a 'results.raw' file of a right type (ab, abx, ab_scale or abc) defined in the test.config file. If the results.raw file type mismatches test.config type either the File Parser or gpResProc program will prompt user that result.raw file is incompatible. Program scans through all subdirectories of the GuineaPigs directory.

You can override the automatic search by selecting the subdirectories that you want to process. You may name one or more subdirectories:

    gpResProc  gp023 gp001
This would select for processing guineapig result files only from directories 'gp023' and 'gp023'.

Program output

Program output format depends on the test type. For example output of the gpResProc program processing a A/B/X -test could look like this:
#subj	A	B	X	answer	time
gp005	smpl2	smpl3	smpl4	smpl3	2.43056
gp000	smpl2	smpl3	smpl4	smpl3	6.48239
gp003	smpl2	smpl3	smpl4	smpl2	23.9952
gp006	smpl2	smpl3	smpl4	smpl2	1.21678
gp007	smpl2	smpl3	smpl4	smpl2	3.6297
gp002	smpl2	smpl3	smpl4	smpl2	33.9026
gp005	smpl1	smpl2	smpl3	smpl2	0.39959
gp000	smpl1	smpl2	smpl3	smpl2	0.371249
gp003	smpl1	smpl2	smpl3	smpl1	6.69518
gp006	smpl1	smpl2	smpl3	smpl1	0.147834
gp007	smpl1	smpl2	smpl3	smpl2	1.18274
gp002	smpl1	smpl2	smpl3	smpl2	0.929281
gp005	smpl4	smpl5	smpl2	smpl5	0.869751
gp000	smpl4	smpl5	smpl2	smpl4	0.386438
.
.
.

Output can be directed to a file or piped to another program with normal unix syntax.


· Results Processing Index · Document index · Guinea Pig ·