
If your ASCII file structure is simple and does not have complex features such as header lines with parameters to be extracted, your files can be imported using either the Import Single ASCII method or the Import Multiple ASCII method. You will still have the option to customize the import settings using controls in the impASC dialog box. Once the needed adjustments are made to ASCII import options, you can save the settings in one of two ways:
To open the impASC dialog box (see the picture below), choose File: Import: Multiple ASCII or File: Import: Single ASCII, check before Show Options Dialog in the ASCII dialog, and then select the import files and click OK.
If you wish to save the settings in the worksheet, you can select Save to <Sheet>; from the Dialog Theme drop-down list in the impASC dialog box. When you click OK, the settings are saved in the active workbook and will remain with the workbook until settings are changed or the window is destroyed. Note, however, that this does not change the default workbook template settings. If you wish to save these settings with the workbook template, you must resave the template (File: Save Template As).
Contents |
| Add Sparklines |
Specify whether to add the sparklines for the imported data.
|
|---|---|
| Import Mode |
This setting determines where the imported data are added:
|
| Template Name |
During importing data, a template can be used. You can type a template in this field or click the browse button to select one. This is only available when Import Mode is Start New Books or Start New Sheets. |
| Data Structure |
ASCII Data Structures are of two types:
Origin can usually "guess" the correct data structure when importing simple ASCII files, but may have difficulty with some files. When files are not correctly imported, you may be able to overcome the problem by specifying that the data file columns are either delimited or fixed width. |
|---|---|
| Delimiter |
If you know that you are working with a delimited file, select Delimited from the Data Structure drop-down list, then choose a delimiting character from the Delimiter drop-down list. If you select Unknown, Origin will search your file, looking for something resembling a repeating delimiter. |
| Other Delimiter |
If you have selected Other from the Delimiter drop-down list, use the Other Delimiter box to type the delimiting character; such as ':' or '/'. |
| Delimiters |
Specify unknown delimiters other than comma, tab, space and semicolon. It is only available when the Delimiter is selected as Unknown or Data Structure is Fixed column widths. |
| Column Widths |
For a fixed column file, set Data Structure to Fixed Column Widths and specify the width in the Column Widths field. Note that you can specify varying column widths by separating each with a comma. If the number of data columns exceeds the number of column width values, Origin uses the last value to set the width for all remaining columns. If you enter a single width value, Origin sets all columns to that width. |
| Numeric Separators |
Numeric separators vary by language. Origin normally uses the decimal and grouping separators specified in your Windows Regional settings. Use this drop-down list to specify an alternate scheme to use when importing your simple ASCII files into the active workbook. |
| Custom Date Format |
Select a date format from the drop-down list, or type in a custom date format string. For more details, please see the Custom Date Format page. |
| Custom Time Format |
Select a time format from the drop-down list, or type a custom time format string. |
| Number of Columns |
Specify n number of columns for import. If the file you are importing contains more than n columns, only the first n columns are imported. If the file contains less than n columns, the entire file is imported without creating additional (empty) worksheet columns. When 0 is selected from the list, Origin imports all columns in the file. |
|---|---|
| Auto Determine Column Types |
When this checkbox is selected, Origin automatically determines whether each column contains text or numeric data and sets each worksheet column's Format accordingly. When the check box is cleared, Origin retains the Format settings of the target worksheet columns. In this case, the input format should be consistent with the worksheet column format to avoid data loss. |
| Min Number of Consistent Lines to Determine Data Structure |
Specify l for the minimum number of consistent lines to determine data structure. When l lines are found to have the same structure, this structure will be used as the data structure for the whole file. |
| Max Number of Consistent Lines to Determine Consistent Structure | Enter a number which exceeds the number of header rows but is less than the number of lines in the file. |
| Number of Main Header Lines |
Some files -- particularly those generated by lab instrumentation -- will have, at the top of the file, some header information that typically identifies the instrument, the operator, the date, the sample number, etc. These are the main header lines. You can use this list to specify where your main header lines are. Header lines typically are not structured in the same way as the data. This control is available only when Auto Determine Subheader Lines checkbox is cleared. |
|---|---|
| Auto Determine Subheader Lines |
Select this checkbox if you want Origin to determine the number of main header and sub header lines automatically. Subheader lines are typically structured the same way as the data. Clear this checkbox if you want to specify these two values by yourself. |
| Line Numbers Start From Bottom |
Select this checkbox, then the line numbers for Short Names, Long Names, Units, Comments From/to, System Parameters From/To, User Parameters From/To will be the numbers counted upwardly from the bottom of subheader sections. Clear this checkbox, if those line numbers are counted from the top. |
| Number of Subheader Lines |
This control is available only when Auto Determine Subheader Lines checkbox are cleared. You can use this list to specify the number of subheader lines of your file. |
| Short Names |
Specify which line of the ASCII file header to use for the worksheet row heading. Specify <none> to leave a row heading empty. |
| Long Names | |
| Units | |
| Comments From/To | |
| System Parameters From/To | |
| User Parameters From/To |
| Auto Rename Using File Name |
If it is checked, Origin will use the default settings to rename the worksheet and workbook name, which is:
|
|---|---|
| Rename Sheet with (Partial) Filename |
Renames the target worksheet with the file name. If a sheet of the specified name already exists, a number is appended to the sheet name. This checkbox is available only when the Auto Rename Using File Name checkbox is selected. |
| Trim Filename From/To |
Use these two text boxes to specify the part of filename that is used to rename the worksheet. |
| Rename Book with (Partial) Filename |
Renames the target workbook with the file name. This checkbox is available only when the Auto Rename Using File Name checkbox is unchecked. |
| Trim Filename From/To |
Use these two text boxes to specify the part of filename that is used to rename the workbook. |
| Rename Long Name for Book only |
Check this to rename the Long Name for workbook only. |
| Include File Path when Renaming Book |
When this is checked, the import file path is appended to the workbook name. |
| Append Filename to Workbook Comments |
Appends filename to the workbook's comment. |
| Append Filename To Column Comments |
Appends filename to the worksheet's Comments header row. If the Comments row is hidden, it will be shown automatically. |
| Include Path when Appending Filename |
When this is checked, the import file path is included with the file name. |
| Partial Import |
Select this checkbox to enable partial import. |
|---|---|
| From/To Column |
Only available when the Partial Import checkbox is selected. Enter two column numbers to specify the column range for partial import. |
| From/To Row |
Only available when the Partial Import checkbox is selected. Enter two row numbers to specify the row range for partial import. |
| Read Rows |
This works with Skip Data Rows. When you specify a number l for Read rows and a number k for Skip Data Rows, l rows are imported and k rows are skipped for every l+k rows. |
| Skip Data Rows |
Only available when Read Rows is not 0. Please see Read Rows for more explanation. |
| To Row |
It is only available when the Partial Import checkbox is selected. Specify the end row for partial import. |
| Text Qualifier |
Specify the text qualifier.
|
|---|---|
| Remove Text Qualifier from Quoted Data |
Select the box to remove quotes upon file import. |
| Remove Leading Zeros from Numbers |
Removes zeros from zero-padded data (data with leading zeros). |
| When Non-numeric is Found in Numeric Field |
The When Non-numeric is Found in Numeric Field list selection controls how Origin proceeds if non-numeric information is encountered in a numeric column below the header lines. Select an option from the associated drop-down list:
|
| Allow Import All Text Data |
Specify whether allow to import all text data. |
| Keep Target Column Format |
Specify whether to keep target column format. |
| Save File Info. in Workbook |
Specify whether to save the file information to the workbook, which can be seen from the Workbook Organizer. Storing the file information requires extra time. So, you may consider clearing this option to improve the importing speed when importing multiple files. |