rm(list=ls())
setwd("/Users/innoshuadmin/Dropbox/RDHeteroTest/RDMonoTest/simulationR2/mktable")
require(stargazer) 

nmodel=4
modelvec=c(0,nmodel,nmodel*2)
smvec=1:3
load(paste("SRDpanelA_model1.RData",sep=""))
rej_DGP1<-cbind(rejincprop_int[modelvec+1,smvec],rejdecprop_int[modelvec+1,smvec])
load(paste("SRDpanelA_model2.RData",sep=""))
rej_DGP2<-cbind(rejincprop_int[modelvec+2,smvec],rejdecprop_int[modelvec+2,smvec])
load(paste("SRDpanelA_model3.RData",sep=""))
rej_DGP3<-cbind(rejincprop_int[modelvec+3,smvec],rejdecprop_int[modelvec+3,smvec])
load(paste("SRDpanelA_model4.RData",sep=""))
rej_DGP4<-cbind(rejincprop_int[modelvec+4,smvec],rejdecprop_int[modelvec+4,smvec])	
rej=rbind(cbind(rej_DGP1,rej_DGP3),cbind(rej_DGP2,rej_DGP4))	
rownames(rej) <- c("n=2000","n=4000","n=8000","n=2000","n=4000","n=8000")
stargazer(rej,digits=3,out = "simutable2.tex") 
