ECG Database Applications Guide Table of Contents


skewedit - edit skew fields of header file(s)


skewedit record skew0 [ skew1 ... skewN ]


This program reads the header(5) file for the specified record, changes the skew fields to match the skew0, skew1, etc. arguments, and rewrites the header file as record.hea in the current directory. skew0 is the skew in samples for signal 0, skew1 is the skew for signal 1, etc. Skews may not be negative; any omitted skews are taken to be zero.

Skew refers to time differences between samples having the same sample number in different signals. Skew may arise while digitizing multitrack analog tape recordings, for example, as a result of differences in the azimuth of the recording and playback heads of the recording equipment. It may be possible to measure skew (for example, by applying test signals simultaneously or at known intervals to all input channels, and then by measurement of the digitized test signals). When this is possible, skewedit can then be used to record the skew measurements in the header file.

For example, assume that a test signal applied simultaneously to all inputs of record abc is determined to appear on signal 0 at sample 30, on signal 1 at sample 28, on signal 2 at sample 28, and on signal 3 at sample 26. In this case, skew0 is 4 (30 - 26), skew1 and skew2 are each 2, and skew3 is 0. The command
skewedit abc 4 2 2 0
would apply the proper correction to the header file for the record. (The final `0' could be omitted from the command.)

Applications built using the DB library (version 9.2 or later) are able to correct for skew (the skew correction is performed by the DB library and is not visible to the application program). Note that skew correction does not require rewriting the signal file(s).

If you wish to create skew-corrected signal files (for example, to use with applications built using earlier versions of the DB library), use xform(1) to do so, using the header file generated by skewedit as input to xform. Note, however, that older applications can generally be updated without source changes simply by recompiling them and linking them with the current DB library.

The shell variable DB should be set and exported (see setdb(1) ).


xform(1) , header(5)


This program is included in the DB Software Package, version 9.0 and later.

Table of Contents