Adjusting the Table/parameter

Problems with modeling
Post Reply
sadiksha123
User
User
Posts: 5
Joined: 3 years ago

Adjusting the Table/parameter

Post by sadiksha123 »

Hi

I am trying to copy data from the excel sheet with dimension of (40*48) but while copying the data are not align ..How can i align for the large table like this ...
Screenshot 2021-01-16 163854.png
User avatar
Renger
Posts: 639
Joined: 7 years ago

Re: Adjusting the Table/parameter

Post by Renger »

Hi
It is never a good idea to copy-paste stuff. If you change your table, you have to do it again, and again.
I would suggest that you use gdxxrw to read the table in your code directly.
If that is not an option, you can save your table from excel into a csv-file and read it with csv2gdx.
Cheers
Renger
____________________________________
Enjoy modeling even more: Read my blog on modeling at The lazy economist
sadiksha123
User
User
Posts: 5
Joined: 3 years ago

Re: Adjusting the Table/parameter

Post by sadiksha123 »

Thank you Renger

I am new so can i know how to read from excel to GAMS .I try doing my self stdy but i confused with so many ideas ....which to follow ...I am attaching my excel file where there are the data's so could you please guide with the most standard method to copy it to GAMS
To Gams .xlsx
(20.58 KiB) Downloaded 219 times
sadiksha123
User
User
Posts: 5
Joined: 3 years ago

Re: Adjusting the Table/parameter

Post by sadiksha123 »

EvToGams.xlsx
(20.58 KiB) Downloaded 228 times

This is my excel sheet ..How can i copy to the GAMS . I am going through the GDXRW but so many options are given i am getting confused which is best suited to my data as i have data for 40 EVS along rows and 48 time interval in column and i have to copy the parameters also .

I am attaching my excel file ..if somebody can help ..it would be greatful ..
User avatar
Renger
Posts: 639
Joined: 7 years ago

Re: Adjusting the Table/parameter

Post by Renger »

Hi
Your tables are all two-dimensional tables, so not many options needed. Work through the examples in the GDXXR documentation (unfortunately, it starts with all options. It is better to start with the examples and if you encounter more difficult tables/problem, you can look through the settings).
Cheers
Renger
____________________________________
Enjoy modeling even more: Read my blog on modeling at The lazy economist
sadiksha123
User
User
Posts: 5
Joined: 3 years ago

Re: Adjusting the Table/parameter

Post by sadiksha123 »

Renger wrote: 3 years ago Hi
Your tables are all two-dimensional tables, so not many options needed. Work through the examples in the GDXXR documentation (unfortunately, it starts with all options. It is better to start with the examples and if you encounter more difficult tables/problem, you can look through the settings).
Cheers
Renger
GDXXR ??
User avatar
Renger
Posts: 639
Joined: 7 years ago

Re: Adjusting the Table/parameter

Post by Renger »

gdxxrw
____________________________________
Enjoy modeling even more: Read my blog on modeling at The lazy economist
Post Reply