6.4.8.3.5 Import Wizard, The Header Variables Page(ASCII)


This page is available when Specify delimiter and Wizard scans for variable names and values is selected on the Variable Extraction page, and there is at least one header line in your data file. Use this page to extract variable values (e.g., parameters, date info) that may be contained in your file header. The top part of this page gives a preview of the header lines.

Import Wizard Header Variables Page.png

Header Variables Controls

Scan lines

Select the range of lines in the header that should be scanned for variables. Enter values by typing a row number, by selecting a number from the drop-down list, or by graphically specifying row numbers.

To specify graphically, select one or more lines in the preview window and click the Refresh button to the right of the Scan lines control.

Delimiter

Specify the Names and Values separator in the header lines.

The dropdown list enumerates standard separators such as tabs, commas, and colons. To use a custom separator, pick Other from the drop-down list and specify your custom character in the adjacent text box.

Scan

Scan the specified lines of the header using the specified separator. The results from the scan are entered in the Name/Value list.

The scan is performed twice. On the first pass, a search is done for the separator on each line of the header. If the separator is found in a line, all characters to the left of the first occurrence of the separator are assigned to the variable name, and all characters to the right of the first occurrence of the separator are assigned to the value of that variable. Thus, a header line such as "Acquisition Date: 10th July 2003" will result in a variable named Acquisition Date and a value for that variable equal to 10th July 2003.

The header lines are then scanned a second time. In this second scan, the lines are searched for the separator and each token found in the line is treated as a separate variable. The variables are then named by the line number and the token position in which they were found. So, in the above example, two variables will be found, having these names and values :

  • L1V1 Acquisition Date
  • 1V2 10th July 2003

This scan method allows users to extract variables from header lines which are of the form of "cquisition Date: 10th July 2003" and also from header lines such as "10, 20, 100, 40, 5". In the latter case, the second scan will extract 5 variables from this line, thus retrieving all values (assuming comma is used as the separator). Note that the dual scan process can result in unwanted variables being added to the list.