Data Connector Improvements in Origin 2020b

Since the introduction of Data Connectors (DC) in Origin 2019b, people are starting to use this method to import their data, and in the process providing us with valuable feedback. We were able to address some issues and make some improvements in Origin 2020b in this area.

Drag and Drop File

In Origin 2020, when the data file supported both DC and older import methods, the 1st time the user drags and drops a file into Origin, the user is prompted to choose which import method to use. From then on, that method will be used for drag and drop.

But in Origin 2020b, we gave DC a higher priority. So if a file has DC support, it will be used automatically, except for the following situations:

  1. User’s import settings are saved in the worksheet,
  2. There is an import filter saved in data file folder or the User Files Folder.

Basically those import filters located in the program folder, the so called system import filters, are ignored if the file is supported by a DC. You can alter this default behavior with a new 2020b system variable, @DDC, which stands for Disable DC (for drag and drop), and details on this will be given later. You may read more about drop and drop from these documentation pages:

In Origin 2020 and earlier versions, if there is a user-defined import filter under the User Files Folder, when the user drags and drops data into Origin, both user-defined filter and system filter will be listed in the Select Filter dialog and the user is prompted to pick one. In Origin 2020b, we don’t show system filter in the dialog. Also if there is only one user-defined filter in the User Files\Filters folder, Origin will directly import with it.

You can alter this by another 2020b system variable, @IFS, which stands for Import Filter in System. By default, the value is 0, which makes the system filter invisible. To make system filters visible to drag and drop, you can put in a value, (bit based) as follows :

1 = *.dat files
2 = *.xls, *.xlsx files
4 = *.txt files
8 = *.csv files
-1 = any files

The @DDC variable mentioned above is using these same bits. Basically @DDC is used to completely prevent using DC in drag and drop, while @IFS will make system filters visible to drag and drop.

About Save Data to Project

When data connector was first introduced in 2019b, Exclude Imported When Saving was automatically turned on and many users were not happy when opening a project file: all the data were not there and they needed to import again. We made a change in Origin 2020 to check data size before excluding data when saving, so that for most files, data are saved in the project. There is no change in this area in 2020b but I will repeat the details on the system variables that control this as follows:

  • @DNS: default is 0, it means to check @FSE or @FSEW, set to 1 to always save data to project.
  • @FSE: Controls threshold file size in kilobytes, for data files. Default = 500, so if file size is > 500k, then Origin will not save that into the project.
  • @FSEW: This is for web based contents. It is the number of worksheet cells after import in the unit of 100. Default is 80, which means that if rows x cols > 80000, then that content will not be saved in project.

In addition, you can save data imported from a connector into the project in these ways:

  • Click on the DC icon and clear the check mark beside Exclude Imported When Saving. which is essentially the same as right-clicking on the window title bar, opening Properties and clearing the check box beside Exclude imported data when saving project.
  • Remove the data connector, which is also a method to allow changing the data.

Other Improvements in Origin 2020b

Connector Buttons Added to Import Toolbar

Three new buttons are added to the Import toolbar for faster data access and easier loading of connected data files.

  • Connect to Data from the Web
  • Connect Multiple Files
  • Import All Connected Data

Improvements to Text/CSV Connector

The Text/CSV Connector (Data: Connect to File) adds support for automatic formatting of date-time data and better wildcard support when defining data block markers.

When importing date-time data into Origin, it has usually been the case that the date-time string is interpreted as a text string — particularly when the date-time data format was not recognized by Origin. This meant that you had to set the containing column as Date or Time, then select or enter a matching date-time format string in the Column Properties dialog. Specifying custom formats could be frustrating because it often required carefully entering a long string of formatting characters.

Now, when connecting to a text file using the Text/CSV Connector, that detail is dealt with automatically. Date and time data components are generally put to separate columns and properly formatted as date and time.

A custom date format is automatically handled when connecting a *.dat file.

Connect Multiple Files

You could drop multiple files onto Origin 2020 and each file would be connected to a new workbook. The same drag-and-drop behavior works in Origin 2020b but we’ve added a new Data: Connect Multiple Files menu command that allows you to set the connector type (CSV, Excel, HDF, MATLAB) and choose your files, with the option to connect all files to new sheets in the same book. The dialog also allows you to enable Open Dialog for First File so that you can adjust settings prior to import.

Add all connected files into the same workbook or matrixbook.

Data Navigator for Data Connector

Data Navigator panel added to worksheet to view and change subset of data to be imported.

E.g. Prior to 2020b, connecting to multi-sheet files was limited to connecting a single sheet at a time. This is no longer the case. Now, when connecting to a multi-sheet MS Excel file for instance, a Data Navigator pane is added to the connected workbook, with the Navigator pane listing all sheets in the Excel file. The sheet that you initially chose for import will be bolded in the Navigator pane, while the remaining, unconnected sheets will be dimmed. You can right-click on any of the unconnected sheets and import that data into the same Origin workbook using the Add and Connect Sheet(s) shortcut menu command.

Connect additional sheets with the Add and Connect Sheet(s) shortcut command.

Further, if you take a moment to configure import of data into your first sheet (i.e. you identify which header row should be treated as Long Name, which as Units, etc.), the remaining sheets — assuming they are similarly structured — will be imported into their own named sheets with all header information properly placed in the worksheet’s column label rows and the sheet tabs named as in the original file.

connecting additional identically-structured sheets is easy.

With Data Navigator, you don’t have to decide what dataset to import at one time. You can right click anytime in the left Data Navigator to import or remove. E.g. with the following netcdf file, i only picked Ion to import. Later I can choose Lat data to import into the same sheet.

Connect to Matrix/Image Data

For some data types e.g. MAT, NetCDF that support matrix or image data, please start a matrix window before connecting to it. E.g. choose File: New: Matrix or click the New Matrix toolbar button. Then drag and drop such data into matrix window or choose corresponding DC under Data: Connect to File or Connect to Web menu.

Drag the slider on top of the window to navigate if there are multiple image/data. Use Matrix’s mini toolbar to toggle data/image view, etc.

Right click in the left Data Navigator window for more options.

Database Connector Improvements

Origin 2020b also includes improvements to Database Connectors, including a new Database Connector dialog for creating new connections. The dialog supports direct connections to an ODBC data source, including by specifying an ODBC connection string. In previous versions, setting up an ODBC connection required going through the Windows Data Link Properties dialog box.

  • Connection string: Select this if you already have a text-based connection string for a given data source (ODBC or OLE DB).
  • ODBC data source: Select this if you have defined an ODBC data source via the Windows ODBC Data Source Administrator applet.
  • ODBC driver: Select this if you have an ODBC driver and want to create a data source applicable to this data connector instance.
  • Windows Data Link Properties dialog: Select this if you are using an OLE DB-based data source such as some SQL Server or Access client libraries.

New Connector Types

Lastly, we’ll mention that there are several new Connector Apps for connecting new data types. These Apps are available free-of-charge and can be installed from the App Center in your Origin software (from the menu, click Data: Connect to File: Add New…); or by downloading the App from the OriginLab File Exchange and dropping it into your Origin workspace.

If you want to try out these new Connector features and Apps but you do not have the latest version of Origin, you can download the latest, full-featured Trial Version of the Origin software and evaluate it — including any of the dozens of free Apps — for a period of 21 days.

That’s it for this post. We hope that this has been informative. If you would like to know more about the latest features and improvements in Origin and OriginPro, please visit the Origin 2020b Highlights page.


メールアドレスが公開されることはありません。 が付いている欄は必須項目です