Search found 67 matches
- 6 days ago
- Forum: API
- Topic: Trouble installing python API
- Replies: 1
- Views: 442
Re: Trouble installing python API
Hi, Chances are that the build architecture of your Python version and the GAMS installation do not match. There are notes on this in the documentation: https://www.gams.com/latest/docs/API_PY_GETTING_STARTED.html#PY_APPLE_ARM You might want to run both commands that are mentioned there in order to ...
- 6 days ago
- Forum: Tools
- Topic: ExcelWriter valueSubstitutions question
- Replies: 4
- Views: 604
Re: ExcelWriter valueSubstitutions question
Eric, All records that do not meet the given expression are removed, also for variables and equations where you might filter on the level only. See the documentation: https://www.gams.com/latest/docs/UG_GAMSCONNECT.html#UG_GAMSCONNECT_FILTER_RULE This is not exactly what you tried to achieve in the ...
- 1 week ago
- Forum: Tools
- Topic: ExcelWriter valueSubstitutions question
- Replies: 4
- Views: 604
Re: ExcelWriter valueSubstitutions question
Hi, The valueSubstitutions option of the ExcelWriter does not work with expressions like <0.00001. It will be considered as a string when the YAML syntax gets parsed. There is the Filter agent that allows actual filtering of records. The following example should give you an idea on how to use it. Al...
- 1 week ago
- Forum: Tools
- Topic: Print from GAMS Studio to PDF
- Replies: 1
- Views: 585
Re: Print from GAMS Studio to PDF
Hi Francisco, Printing a .gms file to PDF works with the normal print dialog in GAMS Studio by selecting an appropriate printer - I was using "Microsoft Print to PDF". LST files are not opened as plain text files but in a Listing Viewer widget. The print option is not available in this cas...
- 2 weeks ago
- Forum: Tools
- Topic: Data exchange from excel to gams (on macOS)
- Replies: 13
- Views: 14078
Re: Data exchange from excel to gams (on macOS)
Hi, Your Connect code fails since the symbols Elastva , Elastx , and Elastmu want to read from the worksheets sheet , acelastx , and friscelast which do not exist in the attached Excel file. If I remove those entries from the Connect instructions, I can see data for the other symbols - e.g. elastc ....
- 3 weeks ago
- Forum: API
- Topic: Python API: Catching Warnings
- Replies: 2
- Views: 5125
Re: Python API: Catching Warnings
Jan,
We did change the implementation of those warnings in the Python Control API to use the warnings module instead of print(). This will become available with the next major release of GAMS.
Best,
Clemens
We did change the implementation of those warnings in the Python Control API to use the warnings module instead of print(). This will become available with the next major release of GAMS.
Best,
Clemens
- 1 month ago
- Forum: Syntax
- Topic: embeddedcode: Python
- Replies: 1
- Views: 898
Re: embeddedcode: Python
Hi, With gams.get() in embedded code Python, you will get all values of a symbol - e.g. level, marginal, etc. for a GAMS variable and need to process them manually afterwards. Here is some code snippet that reads and prints a variable x : embeddedCode Python: var_x = list(gams.get('x')) print(var_x)...
- 1 month ago
- Forum: Tools
- Topic: Data exchange from excel to gams (on macOS)
- Replies: 13
- Views: 14078
Re: Data exchange from excel to gams (on macOS)
Hi, The error indicates that you try to set data for your parameter twice. Perhaps your parameter has data already and you try to set data again from an embedded code section. Anyhow, the following code should bring the data from the Excel sheet into a two dimensional GAMS parameter: Parameter p(*,*...
- 1 month ago
- Forum: API
- Topic: Python API picking up wrong GAMS version
- Replies: 3
- Views: 11648
Re: Python API picking up wrong GAMS version
Hi,
Something seems to put in the GAMS 38 path into your configuration. Have you checked if the PYTHONPATH environment variable is set? Run from the Anaconda command prompt:
Best,
Clemens
Something seems to put in the GAMS 38 path into your configuration. Have you checked if the PYTHONPATH environment variable is set? Run from the Anaconda command prompt:
Code: Select all
echo %PYTHONPATH%
Clemens
- 1 month ago
- Forum: Archive Google Group
- Topic: GAMS Installation Error
- Replies: 3
- Views: 4746
Re: GAMS Installation Error
Hi, This is a Windows problem that can most likely be prevented by running the installer from a command prompt with /SILENT or /VERYSILENT. There is a note on this in the documentation: https://www.gams.com/latest/docs/UG_WIN_INSTALL.html image.png 1. Open command prompt 2. Switch to directory conta...