Dear all,
I’m trying to learn MIRO environment. I have a question on how to proper import parameters on the application.
I’m taking the Cameroon CGE (camcge.gms) model from GAMS library as an example.
I have first parameter declaration where first i wrote the command “$onExternalInput”:
$offIDCProtect
$onExternalInput
Parameter
delta(i) ‘Armington function share parameter (unity)’
ac(i) ‘Armington function shift parameter (unity)’
rhoc(i) ‘Armington function exponent (unity)’
rhot(i) ‘cet function exponent (unity)’
at(i) ‘cet function shift parameter (unity)’
gamma(i) ‘cet function share parameter (unity)’
eta(i) ‘export demand elasticity (unity)’
ad(i) ‘production function shift parameter (unity)’
cles(i) ‘private consumption shares (unity)’
gles(i) ‘government consumption shares (unity)’
depr(i) ‘depreciation rates (unity)’
dstr(i) ‘ratio of inventory investment to gross output (unity)’
kio(i) ‘shares of investment by sector of destination (unity)’
tm0(i) ‘tariff rates (unity)’
te(i) ‘export duty rates (unity)’
itax(i) ‘indirect tax rates (unity)’
alphl(lc,i) ‘labor share parameter in production function (unity)’
…
…
(I’m not writing all the parameters, scalars and tables to not writing too long.)
Then i have parameter initialization where at the end i wrote the command “$offExternalInput” :
depr(i) = zz(“depr”,i);
rhoc(i) = (1/zz(“rhoc”,i)) - 1;
rhot(i) = (1/zz(“rhot”,i)) + 1;
eta(i) = zz(“eta”,i);
tm0(i) = zz(“tm0”,i);
te(i) = 0;
*te(i) = zz(“te”,i);
itax(i) = zz(“itax”,i);
cles(i) = zz(“cles”,i);
gles(i) = zz(“gles”,i);
kio(i) = zz(“kio”,i);
dstr(i) = zz(“dstr”,i);
xllb(i,lc) = xle(i,lc) + (1 - sign(xle(i,lc)));
m0(i) = zz(“m0”,i);
it(i) = yes$m0(i);
in(i) = not it(i);
e0(i) = zz(“e0”,i);
xd0(i) = zz(“xd0”,i);
k0(i) = zz(“k”,i);
pd0(i) = zz(“pd0”,i);
pm0(i) = pd0(i);
pe0(i) = pd0(i);
pwm0(i) = pm0(i)/((1 + tm0(i))*er);
pwe0(i) = pe0(i)/((1 + te(i))*er);
pva0(i) = pd0(i) - sum(j, io(j,i)*pd0(j)) - itax(i);
xxd0(i) = xd0(i) - e0(i);
dst0(i) = zz(“dst”,i);
id0(i) = zz(“id”,i);
ls0(lc) = sum(i, xle(i,lc));
…
…
…
$offExternalInput
Now when i run the MIRO base mode i get the error:
“External input symbol(s) without data initialization:”
delta
ac
rhoc
rhot
at
gamma
eta
ad
cles
gles
depr
dstr
kio
tm0
te
itax
…
…
I think the problem is that some parameters are first declared and then initialized but probably all the parameters need to be declared and then initialized at the same time for MIRO…
Is there any way to overcome this problem or should i modify the code in a proper way?
thank you very much for your help