CLONE

<< Click to Display Table of Contents >>

Navigation:  Gekko User Manual > Gekko statements >

CLONE

Previous pageReturn to chapter overviewNext page

The CLONE statement copies the first-position databank into the (cleared) Ref (reference) databank. After this, all variables in the two banks are identical, and all MULPRT, PRT<m>, PLOT<m>, COMPARE, etc. will show no differences.

 


 

Syntax

 

clone;

 


 

Example

 

You may use the CLONE statement in the following way:

 

model m;
read data;
time 2015 2050;
sim;
clone;
vat += 0.01;
sim;
prt <m> gdp;

 

The CLONE statement makes sure that the first-position and Ref (reference) databanks are identical after the model is simulated for the first time. Hence, the differences (the 'multiplier') regarding the two scenarios can be printed with prt <m>.

 

 


 

Note

 

The READ statement always creates the Ref (reference) databank as an exact copy of the first-position databank after reading. You may use read <first> or read <ref> to read data into the first-position or Ref (reference) databank exclusively. The READ statement is equivalent to read <first> ...; clone;.

 


 

Related statements

 

MODEL, MULPRT, OPEN, READ, SIM