TITLE: Round 2 Calibration Model
DATA: FILE = 
 "C:/Users/colev/Dropbox/aMNLFA_12212017/UMNfix_082021/aMNLFA/inst/extdata/calibration.dat";
VARIABLE: 
NAMES = ID BIN_1 BIN_2 BIN_3 BIN_4 BIN_5 BIN_6 BIN_7 BIN_8 BIN_9 BIN_10 BIN_11
     BIN_12 AGE GENDER STUDY; 
MISSING=.;
!
!
!
USEVARIABLES= BIN_1 BIN_2 BIN_3 BIN_4 BIN_5 BIN_6 BIN_7 BIN_8 BIN_9 BIN_10 BIN_11 BIN_12 
 AGE GENDER STUDY;
! ;
CATEGORICAL= BIN_1 BIN_2 BIN_3 BIN_4 BIN_5 BIN_6 BIN_7 BIN_8 BIN_9 BIN_10 BIN_11 BIN_12 ;
!
CONSTRAINT= AGE STUDY ;
ANALYSIS: ESTIMATOR=ML;ALGORITHM=INTEGRATION;INTEGRATION=MONTECARLO;PROCESSORS=4;
MODEL: [ETA@0];ETA*(veta);
ETA BY BIN_1*(l_1);
ETA BY BIN_2*(l_2);
ETA BY BIN_3*(l_3);
ETA BY BIN_4*(l_4);
ETA BY BIN_5*(l_5);
ETA BY BIN_6*(l_6);
ETA BY BIN_7*(l_7);
ETA BY BIN_8*(l_8);
ETA BY BIN_9*(l_9);
ETA BY BIN_10*(l_10);
ETA BY BIN_11*(l_11);
ETA BY BIN_12*(l_12);
ETA ON AGE; ETA ON STUDY;
BIN_1 on BIN_1 AGE STUDY;

BIN_2 on BIN_2 AGE GENDER STUDY;


BIN_3 on BIN_3 GENDER STUDY;



BIN_4 on BIN_4 AGE;




BIN_5 on BIN_5 GENDER STUDY;





BIN_6 on BIN_6;






BIN_7 on BIN_7;







BIN_8 on BIN_8 GENDER STUDY;








BIN_9 on BIN_9;









BIN_10 on BIN_10;










BIN_11 on BIN_11 AGE;











BIN_12 on BIN_12;
MODEL CONSTRAINT: new( v1*0
l1_0*1   l1_NA*0
l2_0*1   l2_NA*0
l3_0*1   l3_NA*0
l4_0*1   l4_NA*0
l5_0*1   l5_NA*0
l6_0*1   l6_NA*0
l7_0*1   l7_NA*0
l8_0*1   l8_3*0  l8_NA*0
l9_0*1   l9_NA*0
l10_0*1   l10_NA*0
l11_0*1   l11_NA*0
l12_0*1   l12_NA*0
);
veta=1*exp(
v1*AGE+
0);
l_1=l1_0 +l1_NA*BIN_1;
l_2=l2_0 +l2_NA*BIN_2;
l_3=l3_0 +l3_NA*BIN_3;
l_4=l4_0 +l4_NA*BIN_4;
l_5=l5_0 +l5_NA*BIN_5;
l_6=l6_0 +l6_NA*BIN_6;
l_7=l7_0 +l7_NA*BIN_7;
l_8=l8_0 +l8_3*BIN_8 +l8_NA*STUDY;
l_9=l9_0 +l9_NA*BIN_9;
l_10=l10_0 +l10_NA*BIN_10;
l_11=l11_0 +l11_NA*BIN_11;
l_12=l12_0 +l12_NA*BIN_12;
OUTPUT: tech1;
