|
Parameter data: Par |
Top Previous Next |
|
When an item containing data along with identifying set elements is to be read or written one uses
Par=parametername Rng=DataRange Dimensions SymbolOptions Examples: Basic parameter writing is done using commands like (Gdxxrwwrite.gms)
execute_unload 'Gdxxrwwrite.gdx' twodim,threedim,i,j,k,ii; execute "Gdxxrw Gdxxrwwrite.gdx o=gdxxrwss.xls par=twodim Rng=output!a1"
which first creates the GDX file called GdxxrwWrite.gdx then uses the Gdxxrw program to save the parameter called TWODIM into the sheet called output starting at the upper left-hand corner A1 while drawing data from GdxxrwWrite.gdx and writing into the spreadsheet called GdxxrwSS.xls. The resultant spreadsheet segment in the output sheet is as follows
Parameters can be read the using essentially the same command with the name of the source spreadsheet appearing after Gdxxrw as follows (Gdxxrwread.gms)
$call "Gdxxrw gdxxrwss.xls par=distance Rng=sheet1!a20:d23 rdim=1 cdim=1" $GDXin gdxxrwss.gdx $load distance execute "Gdxxrw gdxxrwss.xls par=distance2 Rng=sheet1!a20:d23" execute_load 'gdxxrwss.gdx' distance2 Notes:
|