Command Reference : Command Reference
Open a connection to an external application.
xopen is used to start a COM session with an external application, either R or MATLAB. EViews can only have a single session open at a time; a session must be closed (see xopen) before a new session can be opened.
Set the type of connection to be opened. arg may be “r” (R) or “m” (MATLAB).
If “type=” is the same as a currently open connection, keep original connection since it is already open.
(optional) Set the version of MATLAB or statconnDCOM to which EViews connects when opening a session. If not specified, EViews will use the default ProgID specified in the global options.
Do not open a session log window.
Specify the default case for objects in R or MATLAB using xput. If “case=” is not provided, the default case specified in the global options will be assumed. Note that once a connection has been opened, the case option cannot be changed; you may however, use the “name=” option when using xput to provide an explicit name.
Note that the MATLAB ProgIDs may be of particular interest as MATLAB (R2008a and later) offers several distinct ways in which to connect to the server. The relevant ProgIDs are:
1. “MATLAB.Application”— this ProgID starts a command window version of MATLAB that was most recently used as a server (might not be the latest installed version of MATLAB).
2. “MATLAB.Application.Single”— same as (1) but starts a dedicated server so that other programs looking to use MATLAB cannot connect to your instance.
3. “MATLAB.Autoserver”—starts a command window server using the most recent version of MATLAB.
4. “MATLAB.Autoserver.Single”—same as (3) but starts a dedicated server.
5. “MATLAB.Desktop.Application”—starts the full desktop MATLAB as a server using the most recent version of MATLAB.
Each ProgID may be amended to indicate a specific version of MATLAB. For example, using the ProgID:
instructs EViews to use the full desktop MATLAB GUI for version R2008a (v7.6) as the Automation server.
opens a connection to MATLAB.
xopen(type=r, case=lower)
opens a connection to R and sets the default name-case to lower.
xopen(type=m, progid=MATLAB.Desktop.Application.7.9)
opens a connection to MATLAB 7.9 running with the full desktop GUI.
See “EViews COM Automation Client Support (MATLAB, R, Python)” for discussion. See also “External Program Interface” for global options setting.
See xclose, xget, xput, xrun, and xlog.