You are here

Twins Reared Apart and Together

4 posts / 0 new
Last post
Salutfate's picture
Offline
Joined: 11/22/2013 - 04:34
Twins Reared Apart and Together

Hello

Recently I've been using the twin data from the Chinese National Twin Registry(CNTR) to calculate the heritability of BMI, WC and waist-height ratio. Differently, the data includes both twins reared apart and together in order to obtain the ADCE model. So there are four types of twins in my data: monozygotic twins reared apart(MZA), monozygotic twins reared together(MZT), dizygotic twins reared apart(DZA), dizygotic twins reared together(DZT). However, the scripts I've found are all about ADE or ACE, does anyone has the experience to handle this kind of data or is there any resource on the Internet talking about this method.

Thanks in advance!

neale's picture
Offline
Joined: 07/31/2009 - 15:14
Yes, it is reasonably straightforward

You need to add two new mxModels, one each for the MZA and the DZA. The only difference between the MZA and the MZT group is that MZA has no C in the covariance part of the model. So from the Boulder Workshop 2014 website we might use the univariate script

http://ibg.colorado.edu/cdrom2014/maes/Univariate/twins.R

and modify the lines

covP      <- mxAlgebra( expression= A+D+E, name="V" )
expCovMZ <- mxAlgebra( expression= rbind( cbind(V, A+D), cbind(A+D, V)), name="expCovMZ" )
expCovDZ <- mxAlgebra( expression= rbind( cbind(V, 0.5%x%A+ 0.25%x%D), cbind(0.5%x%A+ 0.25%x%D , V)), name="expCovDZ" )

to become

covP      <- mxAlgebra( expression= A+D+C+E, name="V" )
expCovMZT <- mxAlgebra( expression= rbind( cbind(V, A+D+C), cbind(A+D+C, V)), name="expCovMZT" )
expCovDZT <- mxAlgebra( expression= rbind( cbind(V, 0.5%x%A+ 0.25%x%D + C), cbind(0.5%x%A+ 0.25%x%D , V)), name="expCovDZT" )

you will need a C, so add these lines:

pathC     <- mxMatrix( type="Full", nrow=nv, ncol=nv, free=TRUE, label="c11", name="c" )
covC      <- mxAlgebra( expression=c %*% t(c), name="C" )

Since we started from an ADE model, this is actually correct for the MZA and DZA groups. We just need to add the MZT and DZT models to the overall script and to the model.

# Data objects for Multiple Groups
dataMZT    <- mxData( observed=mzTData, type="raw" )
dataDZT   <- mxData( observed=dzTData, type="raw" )
 
# Objective objects for Multiple Groups
objMZT     <- mxFIMLObjective( covariance="expCovMZT", means="expMean", dimnames=selVars )
objDZT     <- mxFIMLObjective( covariance="expCovDZT", means="expMean", dimnames=selVars )
 
# Construct all 4 
modelMZ   <- mxModel( pars, defAge, meanG, expMean, expCovMZ, dataMZ, objMZ, name="MZ" )
modelDZ   <- mxModel( pars, defAge, meanG, expMean, expCovDZ, dataDZ, objDZ, name="DZ" )
modelMZT   <- mxModel( pars, defAge, meanG, expMean, expCovMZ, dataMZT, objMZT, name="MZT" )
modelDZT   <- mxModel( pars, defAge, meanG, expMean, expCovDZ, dataDZT, objDZT, name="DZT" )
minus2ll  <- mxAlgebra( expression=MZ.objective + DZ.objective + MZT.objective + DZT.objective, name="m2LL" )
obj       <- mxAlgebraObjective( "m2LL" )
AdeModel  <- mxModel( "ADE", pars, modelMZ, modelDZ, minus2ll, obj )

There may be some bits I missed, but this should get you started.

HTH!

Salutfate's picture
Offline
Joined: 11/22/2013 - 04:34
Thanks, neale

Thanks, neale. This is of great help to me and I will try first. I will communicate with you later. Thanks again.

Salutfate's picture
Offline
Joined: 11/22/2013 - 04:34
Good Morning!

Good Morning:
neale.
Back in China, now is the night.
During the daytime, I have consulted to the website you offered me which is really of great help for me, a tyro to OpenMx. During the studying, I have encountered with some problems and I haven't been able to figure it out. The file could be seen in the attachments. Firstly, I use 100 pairs twins to do the exercise in which"reared1":(1)monozygotic twins reared apart(MZA);(2)monozygotic twins reared together(MZT);(3)dizygotic twins reared apart(DZA);(4)dizygotic twins reared together(DZT). The other variable is BMI. However, when meeting with "mxRun"(in"2014-04-22 twinData.R"with a red circle), a problem occured and this sentence(for exemple row 108):
"Warning message:
In model 'twinSat' NPSOL returned a non-zero status code 1. The final iterate satisfies the optimality conditions to the accuracy requested, but the sequence of iterates has not yet converged. NPSOL was terminated because no further improvement could be made in the merit function (Mx status GREEN). "
I have pick the defective row out in the txt"Problem", which is with a red circle in the "2014-04-22 twinData.R".
The training data are attached too.
Sorry to interrupt you again.
Best wishes for you!

  Bin Zhou 
  2014-04-22