! SCRIPT NAME: saturated model AQ and cbcl syndrome scores ! GOAL: analyze AQ (=autism quotient) scores, taking sex & Age effect into account ! DATA: continuous ! INPUT: raw data ! DATA-GROUPS: MZ DZ (in alle groepen zitten ook Sibs!) ! MEANS MODEL: 1 grand mean, taking into account effect of age and sex ! VARIANCE COVARIANCE MODEL: MZ & DZ covariance !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! #define nvar 1 ! number of dependent variables per individual #define ndef 2 ! number of covariates per individual sex and age in this script G1: calculation group Data Calc NGroups=3 Begin matrices; J full 1 nvar free ! grand mean for twins S full 1 nvar free ! grand mean for sibs P full ndef nvar Free ! estimated effects of the covariates A sym nvar nvar free ! twin variance B sym nvar nvar free ! sib variance G sym nvar nvar free ! covariance MZt1-t2 H sym nvar nvar free ! covariance DZt1-t2 I sym nvar nvar free ! covariance MZtwin-sib en DZtwin-sib End matrices; EQ J 1 1 1 S 1 1 1 !equal means twin-sib EQ A 1 1 1 B 1 1 1 !equal variances twin-sib !provide starting values st 102 J 1 1 S 1 1 ! starting values mean AQ st 90 A 1 1 B 1 1 ! variance st 30 G 1 1 ! covar st 25 H 1 1 ! covar st 20 I 1 1 ! covar st -.4 P 1 1 st -.4 P 2 1 ! starting values voor definition variables age - sex Begin Algebra; T = \stnd(A|G|I_G|A|I_I|I|B) ; !off-diagonal is MZ correlation U = \stnd(A|H|I_H|A|I_I|I|B) ; !off-diagonal is DZ correlation End Algebra ; Labels row P age sex !Drop @0 P 1 1 1 ! no age effect !Drop @0 P 1 2 1 ! no sex effect option no_output end G2: MZ twins ! MZ Data Ninput_vars=36 ! Number of variables per family missing=-1.00 ! Missing values voor afhankelijke variabelen !NB: missing values dependent vars moeten andere waarden hebben (hier -4.00) Rectangular file=Comb_AQ_YSR.dat ! read raw data, this is the file created in SPSS Labels ! provide labels for the variables ntrid zyg5gr zygMZDZ age1 sekse1 wit1 som1 anx1 soc1 tho1 att1 del1 agg1 AQ1 age2 sekse2 wit2 som2 anx2 soc2 tho2 att2 del2 agg2 AQ2 age3 sekse3 wit3 som3 anx3 soc3 tho3 at3 del3 agg3 AQ3 select if zygMZDZ = 1 ! select if zygosity is MZ select age1 sekse1 AQ1 age2 sekse2 AQ2 age3 sekse3 AQ3; Definition age1 sekse1 age2 sekse2 age3 sekse3 ; Matrices = Group 1 ! get all matrices from group 1 V Full 1 ndef fix ! observed covariates for twin 1 W Full 1 ndef fix ! observed covariates for twin 2 X Full 1 ndef fix ! observed covariates for sib End matrices; Specify V age1 sekse1; Specify W age2 sekse2 ; Specify X age3 sekse3 ; Means J+V*P | J+W*P | S+X*P; ! means model Covariances ! variance/covariance model A | G | I _ G | A | I_ I | I | B ; end G3: DZ twins ! DZ twins plus 1 sib Data Ninput_vars=36 ! Number of variables per family missing=-1.00 ! Missing values voor afhankelijke variabelen !NB: missing values dependent vars moeten andere waarden hebben (hier -4.00) Rectangular file=Comb_AQ_YSR.dat ! read raw data, this is the file created in SPSS Labels ntrid zyg5gr zygMZDZ age1 sekse1 wit1 som1 anx1 soc1 tho1 att1 del1 agg1 AQ1 age2 sekse2 wit2 som2 anx2 soc2 tho2 att2 del2 agg2 AQ2 age3 sekse3 wit3 som3 anx3 soc3 tho3 at3 del3 agg3 AQ3 select if zygMZDZ = 2 ! select if zygosity is DZ select age1 sekse1 AQ1 age2 sekse2 AQ2 age3 sekse3 AQ3; Definition age1 sekse1 age2 sekse2 age3 sekse3 ; Matrices = Group 1 ! get all matrices from group 1 V Full 1 ndef fix ! observed covariates for twin 1 W Full 1 ndef fix ! observed covariates for twin 2 X Full 1 ndef fix ! observed covariates for sib End matrices; Specify V age1 sekse1; Specify W age2 sekse2 ; Specify X age3 sekse3; Means J+V*P | J+W*P | S+X*P; ! means model Covariances ! variance/covariance model A| H | I _ H | A | I_ I | I | B ; option Mx%P= outlier.dat ! see Mx manual Option saveres end