Including External Files with @FILE

The @FILE interface function in LINGO allows you to include data from external text files anywhere in your model. This is particularly useful for incorporating data stored in text files into your sets and data sections.

The syntax for the @FILE function is:

@FILE( 'filename')

where filename is the name of the file to include text from. When this function is encountered in a model, LINGO will continue to take text from this file until it encounters either the end-of-file mark or a LINGO end-of-record mark (~). For subsequent @FILE references in the same model that use the same file name, LINGO resumes taking input from the file at the point where it left off. Nesting of @FILE function calls (embedding an @FILE in a file that is itself called by @FILE) is not allowed.