#Scenario (g) in Romdhani et al. (2014): 4 SNPs mapped to 2 genes
#and 4 traits involved in 2 clinical pathways.
#In total: 8 observed variables and 4 latent variables.
#One of the traits is involved in both clinical pathways.
#One gene is connected to one of the clinical pathways and the other
#to both of them.
data(GenPhen)
W0 <- matrix(c(rep(1,2),rep(0,8),rep(1,2),rep(0,8),rep(1,3),rep(0,7),rep(1,2)),nrow=8,ncol=4)
B0 <- matrix(c(rep(0,8),rep(1,2),rep(0,3),1,rep(0,2)),nrow=4,ncol=4)
res<-GSCAestim(data=GenPhen,W0,B0)
Run the code above in your browser using DataLab