:mod:`gdx2py.gdxfile` ===================== .. py:module:: gdx2py.gdxfile .. autoapi-nested-parse:: Module for working with GAMS GDX files Module Contents --------------- .. data:: GMS_DTYPES .. data:: GDX_DTYPE_TEXT :annotation: = U254 .. data:: GDX_DTYPE_LABEL :annotation: = U63 .. data:: GDX_DTYPE_NUM :annotation: = f8 .. data:: EPS_VALUE .. data:: SPECIAL_VALUES .. data:: GMS_USERINFO_SET_PARAMETER :annotation: = 0 .. py:class:: GdxFile(filename: str, mode: str = 'r', gams_dir: str = None) Bases: :class:`object` Class for working with a gdx file Use subscripting (gdx_object['']) to get/set a GAMS set or parameter symbol. .. attribute:: filename Absolute filename :type: str Constructor for GdxFile :param filename: str :param mode: File open mode: 'r' for reading, 'w' for writing, 'w+' for appending (replaces existing symbol) :param gams_dir: Location of GAMS installation directory :type gams_dir: optional :raises RuntimeError: Unable to load gdx library, invalid mode :raises FileNotFoundError: Input file not found :raises ValueError: Unsupported mode :raises OSError: Unable to read/write file :raises Exception: Other errors .. method:: keys(self) .. method:: close(self) .. method:: symrange(sym_count) :staticmethod: