# Choi, B. and Kim, K. (2006), 
# 'Testing goodness-of-fit for Laplace distribution based on maximum entropy', 
# Statistics, Vol. 40, No. 6, pp. 517-531. 

# Regenerate table 6 from choi2006 (page 525) 
law.index <- 1
M <- 5*10^4
vectn <- c(10,20,35,50) 
levels <- 0.05
stat.indices <- c(51,53,52,43,44,42,45,46) 
law.indices <- c(2,8,4,3,7) 
alter <- list(stat51=4,stat53=4,stat52=4,stat43=3,stat44=3,stat42=3,stat45=3,stat46=3) 
parlaws <- list(law2=c(0,1),law8=c(10),law4=c(0,1),law3=c(0,1),law7=c(0,1)) 

for (n in vectn) { 
  critval <- many.crit(law.index,stat.indices,M,n,levels,alter,law.pars=NULL,parstats=NULL) 
  table6 <- powcomp.fast(law.indices,stat.indices,n,M,levels,critval,alter,parlaws,parstats=NULL,nbclus=1,null.law.index=law.index) 
  print(table6,digits=1,latex.output=FALSE)
} 

# LaTex output : latex.output=TRUE 


