extractDocumentation {goxygen}R Documentation

extractDocumentation

Description

Extracts doxygen-like GAMS documentation. Entries are introduced with an @type at the beginning of the line. In case of @realization also GAMS code is read and interpreted, in all other cases only the specific documentation comment is evaluated.

Usage

extractDocumentation(path, start_type = NULL, comment = "*'")

Arguments

path

path to the file(s) which should be evaluated

start_type

set type for first line of code. This can be useful to extract documentation even if no documentation type has been set (e.g reading equations.gms as type realization)

comment

comment chars used for documentation comments

Value

a list of documentation pieces with type as name of each element

Author(s)

Jan Philipp Dietrich

See Also

goxygen

Examples

mainfile <- paste0(system.file("dummymodel",package="gms"),"/main.gms")
calcfile <- paste0(system.file("dummymodel",package="gms"),
                           "/modules/02_crazymodule/complex/calculations.gms")
# extracting information from the main file of the model                            
extractDocumentation(mainfile)
# extracting information from a file with some equations in it
extractDocumentation(calcfile)


[Package goxygen version 1.0.3 Index]