Table of Contents


cclink - modify ERP log file flags for events in one condition code based on events in another condition code.


cclink cmdfile logfile



Note: It is assumed that you understand the nature of the ERP Continuous Digitization System, including the ERP log file structure. If this is not true, you should first read the document, "An Overview of the Continuous Data digitization and Averaging System", by J.C. Hansen.

cclink is a special purpose program for modifying an ERP log file. It is used to modify log flags for events in one condition code based on events in another condition code. The name cclink reflects the notion of "linking" condition codes. Typically, cclink is used in conjunction with cdbl(1) . For example, you could use cclink to modify log flags in condition code 1 based on sequences of events found in condition code 2. You could then use cdbl(1) with a bin list descriptor file that sorts events into various bins based on the log flags in condition code 1 that have been modified by cclink.

cmdfile is an ASCII file containing cclink commands. These commands define all the actions that cclink can perform on a logfile, and are described in the "Command File Format" section of this document.

logfile is the name of the ERP log file that cclink is to modify. Since cclink actually modifies logfile rather than creating a new log file with all the desired modifications, it would be wise to make a backup of logfile before running cclink with it.

sampling rate is the data sampling rate in Hz that was used when creating logfile . The sampling rate is needed because some commands in cmdfile can use timing information (e.g. "response times") in determining whether or not to modify a particular log flag.

Once cclink is started, it operates silently until it is finished. The only output is from error messages.

Command File Format

cclink command file is a very simple ascii file (possibly created with the vi editor) that contains one or more commands that follow a well defined syntax that cclink understands. One command per line is allowed. If a line starts with the pound sign (#), cclink considers it to be a comment, and ignores it. Likewise, cclink ignore blank lines in the command file. If you have a really long command, it can be on more than one line by ending all but the last line with a backslash () character. However, the total length of the command is limited to 256 characters. Finally, you can use spaces or tabs to indent a command file for purposes of readability.

Knowing the motivation for the command file syntax will probably help you understand it and even remember it when you don’t have this manual in front of you to help. First, since people who use cclink will almost definitely also be using cdbl(1) , it was desirous to make the cclink syntax very similar to the cdbl(1) syntax. Second, the cclink command syntax corresponds to what the cclink program is actually doing as it processes a log file. To understand this second point, consider an example: We have a memory experiment that consists of a study phase and a test phase. When we average the data, we want to put epochs for studied words that were correctly recognized in the test phase in separate bins from studied words that were not recognized in the test phase. The study phase is assigned condition code 1, and the words were assigned event codes 1-20. The test phase is assigned condition code 2, and the words are assigned event codes 1-40 (where 21-40 are unstudied). There are also event codes in both conditions for the subject responses. 1024 is a correct response in condition 2 (the test phase). What we would like cclink to do is to look through the log file, find any event code in condition 2 in the range 1-20 that is also followed by a 1024, then go back and set flag number one for each of these events in condition 1.

See Also



Ronald Ohst

Table of Contents