Gretl Manual: Gnu Regression, Econometrics and Time-series Library | ||
---|---|---|
Prev | Chapter 12. Options, arguments and path-searching | Next |
When the name of a data file or script file is supplied to gretl or gretlcli on the command line (see the Section called gretl and the Section called gretlcli), the file is looked for as follows:
"As is". That is, in the current working directory or, if a full path is specified, at the specified location.
In the user's gretl directory (see Table 12-1 for the default values).
In any immediate sub-directory of the user's gretl directory.
In the case of a data file, search continues with the main gretl data directory. In the case of a script file, the search proceeds to the system script directory. See Table 12-1 for the default settings.
In the case of data files the search then proceeds to all immediate sub-directories of the main data directory.
Table 12-1. Default path settings
Linux | MS Windows | |
---|---|---|
User directory | $HOME/gretl | PREFIX\gretl\user |
System data directory | PREFIX/share/gretl/data | PREFIX\gretl\data |
System script directory | PREFIX/share/gretl/scripts | PREFIX\gretl\scripts |
Note: PREFIX denotes the base directory chosen at the time gretl is installed. |
Thus it is not necessary to specify the full path for a data or script file unless you wish to override the automatic searching mechanism. (This also applies within gretlcli, when you supply a filename as an argument to the open or run commands.)
When a command script contains an instruction to open a data file, the search order for the data file is as stated above, except that the directory containing the script is also searched, immediately after trying to find the data file "as is".
Under MS Windows configuration information for gretl and gretlcli is stored in the Windows registry. A suitable set of registry entries is created when gretl is first installed, and the settings can be changed under gretl's "File, Preferences" menu. In case anyone needs to make manual adjustments to this information, the entries can be found (using the standard Windows program regedit.exe) under Software\gretl in HKEY_CLASSES_ROOT (the main gretl directory and the command to invoke gnuplot) and HKEY_CURRENT_USER (all other configurable variables).