Hello everyone,
I am a very beginner of GAMS. I have just completed my first model in gams, but I was not able to test it on the real dataset because I was not able to import data.
So this is the code I’m working with:
Set pp "New production" / pp1, pp2, pp3, pp4, pp5, pp6, pp7, pp8, pp9, pp10, pp11, pp12, pp13, pp14, pp15, pp16, pp17, pp18, pp19, pp20, pp21, pp22, pp23, pp24, pp26, pp25, pp27, pp28, pp29, pp30, pp31, pp32, pp33, pp34, pp35, pp36, pp37, pp38, pp39, pp40, pp41, pp42, pp43, pp44, pp45, pp46, pp47, pp48, pp49, pp50, pp51, pp52, pp53, pp54, pp55, pp56, pp57, pp58, pp59, pp60, pp61, pp62, pp63, pp64, pp65, pp66, pp67, pp69, pp68, pp70, pp71, pp72, pp73, pp74, pp75, pp76, pp77, pp78, pp79, pp80, pp81, pp82, pp83/;
$call gdxxrw.exe DATA.xlsx par=t rng=Sheet1!D2:D84
Parameter t(pp);
$gdxin DATA.gdx
$load t
$gdxin
display t;
My first question would be: Is there any way to import the “pp” as a set from the range F1:F84 instead of doing it manually?
Second question: In the code I would like to store the times related to domain’s elements. Why the program returns me a dimension problem?
I’m attaching the excel file i’m working with.
Thank you for your help.
All the best, Leonardo
DATA.xlsx (11.3 KB)