CRAN Package Check Results for Package MCMCpack

Last updated on 2015-12-29 00:46:46.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-gcc 1.3-3 147.52 39.50 187.02 ERROR
r-devel-linux-x86_64-fedora-clang 1.3-3 586.86 ERROR
r-devel-linux-x86_64-fedora-gcc 1.3-3 387.72 ERROR
r-devel-osx-x86_64-clang 1.3-3 680.09 ERROR
r-devel-windows-ix86+x86_64 1.3-3 361.00 130.00 491.00 ERROR
r-patched-linux-x86_64 1.3-3 145.18 40.48 185.67 NOTE
r-patched-solaris-sparc 1.3-3 1783.50 NOTE
r-patched-solaris-x86 1.3-3 374.30 NOTE
r-release-linux-x86_64 1.3-3 145.46 39.90 185.37 NOTE
r-release-osx-x86_64-mavericks 1.3-3 NOTE
r-release-windows-ix86+x86_64 1.3-3 459.00 166.00 625.00 NOTE
r-oldrel-windows-ix86+x86_64 1.3-3 469.00 139.00 608.00 NOTE

Check Details

Version: 1.3-3
Check: installed package size
Result: NOTE
     installed size is 24.6Mb
     sub-directories of 1Mb or more:
     libs 23.9Mb
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-ix86+x86_64, r-patched-linux-x86_64, r-release-linux-x86_64, r-release-osx-x86_64-mavericks, r-release-windows-ix86+x86_64, r-oldrel-windows-ix86+x86_64

Version: 1.3-3
Check: top-level files
Result: NOTE
    Non-standard file/directory found at top level:
     ‘HISTORY’
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-patched-linux-x86_64, r-release-linux-x86_64

Version: 1.3-3
Check: dependencies in R code
Result: NOTE
    There are ::: calls to the package's namespace in its code. A package
     almost never needs to use ::: for its own objects:
     ‘MCMCresidualBreakAnalysis’
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-osx-x86_64-clang, r-devel-windows-ix86+x86_64, r-patched-linux-x86_64, r-patched-solaris-sparc, r-patched-solaris-x86, r-release-linux-x86_64, r-release-osx-x86_64-mavericks, r-release-windows-ix86+x86_64, r-oldrel-windows-ix86+x86_64

Version: 1.3-3
Check: R code for possible problems
Result: NOTE
    dtomogplot: no visible binding for global variable ‘heat.colors’
    dtomogplot: no visible global function definition for ‘par’
    dtomogplot: no visible global function definition for ‘layout’
    dtomogplot: no visible global function definition for ‘lcm’
    dtomogplot: no visible global function definition for ‘plot.new’
    dtomogplot: no visible global function definition for ‘plot.window’
    dtomogplot: no visible global function definition for ‘rect’
    dtomogplot: no visible global function definition for ‘axis’
    dtomogplot: no visible global function definition for ‘box’
    dtomogplot: no visible global function definition for ‘plot’
    dtomogplot: no visible global function definition for ‘abline’
    mptable: no visible global function definition for ‘is’
    plot.qrssvs: no visible global function definition for ‘dotplot’
    plot.qrssvs : <anonymous>: no visible global function definition for
     ‘panel.abline’
    plot.qrssvs : <anonymous>: no visible global function definition for
     ‘panel.dotplot’
    plotChangepoint: no visible global function definition for ‘par’
    plotChangepoint: no visible global function definition for ‘plot’
    plotChangepoint: no visible global function definition for ‘axis’
    plotChangepoint: no visible global function definition for ‘axTicks’
    plotChangepoint: no visible global function definition for ‘lines’
    plotIntervention: no visible global function definition for ‘plot’
    plotIntervention: no visible global function definition for ‘abline’
    plotIntervention: no visible global function definition for ‘lines’
    plotState: no visible global function definition for ‘plot’
    plotState: no visible global function definition for ‘axis’
    plotState: no visible global function definition for ‘axTicks’
    plotState: no visible global function definition for ‘lines’
    plotState: no visible global function definition for ‘points’
    plotState: no visible global function definition for ‘legend’
    tomogplot: no visible global function definition for ‘par’
    tomogplot: no visible global function definition for ‘plot’
    tomogplot: no visible global function definition for ‘rect’
    tomogplot: no visible global function definition for ‘abline’
    tomogplot: no visible global function definition for ‘box’
    topmodels: no visible global function definition for ‘is’
    write.Scythe: no visible global function definition for ‘write.table’
    Undefined global functions or variables:
     abline axTicks axis box dotplot heat.colors is layout lcm legend
     lines panel.abline panel.dotplot par plot plot.new plot.window points
     rect write.table
    Consider adding
     importFrom("grDevices", "heat.colors")
     importFrom("graphics", "abline", "axTicks", "axis", "box", "layout",
     "lcm", "legend", "lines", "par", "plot", "plot.new",
     "plot.window", "points", "rect")
     importFrom("methods", "is")
     importFrom("utils", "write.table")
    to your NAMESPACE (and ensure that your DESCRIPTION Imports field
    contains 'methods').
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-ix86+x86_64

Version: 1.3-3
Check: Rd line widths
Result: NOTE
    Rd file 'HMMpanelFE.Rd':
     \examples lines wider than 100 characters:
     y[j:(j+T-1)] <- ((1-weight)*true.mean + (1-weight)*rnorm(T, 0, true.sigma) + (1-weight)*true.alpha1[i]) +
    
    Rd file 'MCMCbinaryChange.Rd':
     \examples lines wider than 100 characters:
     model0 <- MCMCbinaryChange(y, m=0, c0=2, d0=2, mcmc=1000, burnin=1000, verbose=500, marginal.likelihood = "Chib95")
     model1 <- MCMCbinaryChange(y, m=1, c0=2, d0=2, mcmc=1000, burnin=1000, verbose=500, marginal.likelihood = "Chib95")
     model2 <- MCMCbinaryChange(y, m=2, c0=2, d0=2, mcmc=1000, burnin=1000, verbose=500, marginal.likelihood = "Chib95")
     model3 <- MCMCbinaryChange(y, m=3, c0=2, d0=2, mcmc=1000, burnin=1000, verbose=500, marginal.likelihood = "Chib95")
     model4 <- MCMCbinaryChange(y, m=4, c0=2, d0=2, mcmc=1000, burnin=1000, verbose=500, marginal.likelihood = "Chib95")
     model5 <- MCMCbinaryChange(y, m=5, c0=2, d0=2, mcmc=1000, burnin=1000, verbose=500, marginal.likelihood = "Chib95")
    
    Rd file 'MCMCintervention.Rd':
     \usage lines wider than 90 characters:
     prediction.type=c("trend","ar"), change.type=c("fixed", "random", "all"),
     \examples lines wider than 100 characters:
     plotIntervention(ar1fixed, start=1871, main="Forward Analysis", alpha= 0.5, ylab="Nile River flow", xlab="Year")
     plotIntervention(ar1fixed, forward=FALSE, start=1871, main="Backward Analysis", alpha= 0.5, ylab="Nile River flow", xlab="Year")
    
    Rd file 'MCMCirtHier1d.Rd':
     \examples lines wider than 100 characters:
     scMiss[matrix(as.logical(rbinom(nrow(SupremeCourt)*ncol(SupremeCourt), 1, .1)), dim(SupremeCourt))] <- NA
    
    Rd file 'MCMCirtKdHet.Rd':
     \examples lines wider than 100 characters:
     "deviations from the party line are attributable","to idiosyncrasy rather than moderation."),cex=0.5)
    
    Rd file 'MCMCregress.Rd':
     \examples lines wider than 100 characters:
     posterior <- MCMCregress(Y~X, b0=0, B0 = 0.1, sigma.mu = 5, sigma.var = 25, data=line, verbose=1000)
    
    Rd file 'MCMCregressChange.Rd':
     \examples lines wider than 100 characters:
     model1 <- MCMCregressChange(formula, m=1, b0=b0, B0=B0, sigma.mu=sigma.mu, sigma.var=sigma.var, marginal.likelihood="Chib95")
     model2 <- MCMCregressChange(formula, m=2, b0=b0, B0=B0, sigma.mu=sigma.mu, sigma.var=sigma.var, marginal.likelihood="Chib95")
     model3 <- MCMCregressChange(formula, m=3, b0=b0, B0=B0, sigma.mu=sigma.mu, sigma.var=sigma.var, marginal.likelihood="Chib95")
     model4 <- MCMCregressChange(formula, m=4, b0=b0, B0=B0, sigma.mu=sigma.mu, sigma.var=sigma.var, marginal.likelihood="Chib95")
     model5 <- MCMCregressChange(formula, m=5, b0=b0, B0=B0, sigma.mu=sigma.mu, sigma.var=sigma.var, marginal.likelihood="Chib95")
    
    Rd file 'plotState.Rd':
     \usage lines wider than 90 characters:
     plotState(mcmcout, main="Posterior Regime Probability", ylab=expression(paste("Pr(", S[t], "= k |", Y[t], ")")),
    
    Rd file 'testpanelSubjectBreak.Rd':
     \examples lines wider than 100 characters:
     y[j:(j+T-1)] <- ((1-weight)*true.mean + (1-weight)*rnorm(T, 0, true.sigma) + (1-weight)*true.alpha1[i]) +
    
    These lines will be truncated in the PDF manual.
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-patched-linux-x86_64, r-release-linux-x86_64

Version: 1.3-3
Check: compilation flags in Makevars
Result: NOTE
    Package has both ‘src/Makevars.in’ and ‘src/Makevars’.
    Installation with --no-configure' is unlikely to work. If you intended
    ‘src/Makevars’ to be used on Windows, rename it to ‘src/Makevars.win’
    otherwise remove it. If ‘configure’ created ‘src/Makevars’, you need a
    ‘cleanup’ script.
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-osx-x86_64-clang, r-devel-windows-ix86+x86_64, r-patched-linux-x86_64, r-patched-solaris-sparc, r-patched-solaris-x86, r-release-linux-x86_64, r-release-osx-x86_64-mavericks, r-release-windows-ix86+x86_64, r-oldrel-windows-ix86+x86_64

Version: 1.3-3
Check: examples
Result: ERROR
    Running examples in ‘MCMCpack-Ex.R’ failed
    The error most likely occurred in:
    
    > ### Name: MCMCoprobitChange
    > ### Title: Markov Chain Monte Carlo for Ordered Probit Changepoint
    > ### Regression Model
    > ### Aliases: MCMCoprobitChange
    > ### Keywords: models
    >
    > ### ** Examples
    >
    > set.seed(1909)
    > N <- 200
    > x1 <- rnorm(N, 1, .5);
    >
    > ## set a true break at 100
    > z1 <- 1 + x1[1:100] + rnorm(100);
    > z2 <- 1 -0.2*x1[101:200] + rnorm(100);
    > z <- c(z1, z2);
    > y <- z
    >
    > ## generate y
    > y[z < 1] <- 1;
    > y[z >= 1 & z < 2] <- 2;
    > y[z >= 2] <- 3;
    >
    > ## inputs
    > formula <- y ~ x1
    >
    > ## fit multiple models with a varying number of breaks
    > out1 <- MCMCoprobitChange(formula, m=1,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.30200
    
    
     Acceptance rate for state 2 is 0.33400
    
     The number of observations in state 1 is 00103
     The number of observations in state 2 is 00097
     beta 0 = 0.25560 0.53118
     beta 1 = -0.09097 0.13030
     gamma 0 = 0.79054
     gamma 1 = 1.14920
    logmarglike = -220.04555
    loglike = -192.47056
    log_prior = -4.31181
    log_beta = 4.28397
    log_P = 3.68247
    log_gamma = 15.29673
    > out2 <- MCMCoprobitChange(formula, m=2,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.53400
    
    
     Acceptance rate for state 2 is 0.86800
    
    
     Acceptance rate for state 3 is 0.22400
    
     The number of observations in state 1 is 00107
     The number of observations in state 2 is 00001
     The number of observations in state 3 is 00092
     beta 0 = 0.13360 0.70828
     beta 1 = 0.22094 -0.47864
     beta 2 = 0.40736 -0.28520
     gamma 0 = 0.66271
     gamma 1 = 5.38704
     gamma 2 = 1.34721
    logmarglike = -nan
    loglike = -197.66532
    log_prior = -7.77053
    log_beta = 2.66115
    log_P = 4.99484
    log_gamma = -nan
    > out3 <- MCMCoprobitChange(formula, m=3,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.24000
    
    
     Acceptance rate for state 2 is 0.87600
    
    
     Acceptance rate for state 3 is 0.64700
    
    
     Acceptance rate for state 4 is 0.48900
    
     The number of observations in state 1 is 00102
     The number of observations in state 2 is 00003
     The number of observations in state 3 is 00008
     The number of observations in state 4 is 00087
     beta 0 = -0.08525 0.82141
     beta 1 = 0.15273 -0.06258
     beta 2 = -0.24026 -0.10814
     beta 3 = -0.49359 0.31134
     gamma 0 = 0.95969
     gamma 1 = 1.49675
     gamma 2 = 23.05777
     gamma 3 = 0.88755
    logmarglike = -nan
    loglike = -195.16892
    log_prior = -10.05155
    log_beta = 4.60715
    log_P = 5.73137
    log_gamma = -nan
    >
    > ## find the most reasonable one
    > BayesFactor(out1, out2, out3)
    Error in array(NA, M, dimnames = model.names) : 'dimnames' must be a list
    Calls: BayesFactor -> array
    Execution halted
Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc

Version: 1.3-3
Check: R code for possible problems
Result: NOTE
    plot.qrssvs: no visible global function definition for ‘dotplot’
    plot.qrssvs : <anonymous>: no visible global function definition for
     ‘panel.abline’
    plot.qrssvs : <anonymous>: no visible global function definition for
     ‘panel.dotplot’
    Undefined global functions or variables:
     dotplot panel.abline panel.dotplot
Flavor: r-devel-osx-x86_64-clang

Version: 1.3-3
Check: examples
Result: ERROR
    Running examples in ‘MCMCpack-Ex.R’ failed
    The error most likely occurred in:
    
    > ### Name: MCMCoprobitChange
    > ### Title: Markov Chain Monte Carlo for Ordered Probit Changepoint
    > ### Regression Model
    > ### Aliases: MCMCoprobitChange
    > ### Keywords: models
    >
    > ### ** Examples
    >
    > set.seed(1909)
    > N <- 200
    > x1 <- rnorm(N, 1, .5);
    >
    > ## set a true break at 100
    > z1 <- 1 + x1[1:100] + rnorm(100);
    > z2 <- 1 -0.2*x1[101:200] + rnorm(100);
    > z <- c(z1, z2);
    > y <- z
    >
    > ## generate y
    > y[z < 1] <- 1;
    > y[z >= 1 & z < 2] <- 2;
    > y[z >= 2] <- 3;
    >
    > ## inputs
    > formula <- y ~ x1
    >
    > ## fit multiple models with a varying number of breaks
    > out1 <- MCMCoprobitChange(formula, m=1,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.30200
    
    
     Acceptance rate for state 2 is 0.33400
    
     The number of observations in state 1 is 00103
     The number of observations in state 2 is 00097
     beta 0 = 0.25560 0.53118
     beta 1 = -0.09097 0.13030
     gamma 0 = 0.79054
     gamma 1 = 1.14920
    logmarglike = -220.04555
    loglike = -192.47056
    log_prior = -4.31181
    log_beta = 4.28397
    log_P = 3.68247
    log_gamma = 15.29673
    > out2 <- MCMCoprobitChange(formula, m=2,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.53400
    
    
     Acceptance rate for state 2 is 0.86800
    
    
     Acceptance rate for state 3 is 0.22400
    
     The number of observations in state 1 is 00107
     The number of observations in state 2 is 00001
     The number of observations in state 3 is 00092
     beta 0 = 0.13360 0.70828
     beta 1 = 0.22094 -0.47864
     beta 2 = 0.40736 -0.28520
     gamma 0 = 0.66271
     gamma 1 = 5.38704
     gamma 2 = 1.34721
    logmarglike = nan
    loglike = -197.66532
    log_prior = -7.77053
    log_beta = 2.66115
    log_P = 4.99484
    log_gamma = nan
    > out3 <- MCMCoprobitChange(formula, m=3,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.24000
    
    
     Acceptance rate for state 2 is 0.87600
    
    
     Acceptance rate for state 3 is 0.64700
    
    
     Acceptance rate for state 4 is 0.48900
    
     The number of observations in state 1 is 00102
     The number of observations in state 2 is 00003
     The number of observations in state 3 is 00008
     The number of observations in state 4 is 00087
     beta 0 = -0.08525 0.82141
     beta 1 = 0.15273 -0.06258
     beta 2 = -0.24026 -0.10814
     beta 3 = -0.49359 0.31134
     gamma 0 = 0.95969
     gamma 1 = 1.49675
     gamma 2 = 23.05777
     gamma 3 = 0.88755
    logmarglike = nan
    loglike = -195.16892
    log_prior = -10.05155
    log_beta = 4.60715
    log_P = 5.73137
    log_gamma = nan
    >
    > ## find the most reasonable one
    > BayesFactor(out1, out2, out3)
    Error in array(NA, M, dimnames = model.names) : 'dimnames' must be a list
    Calls: BayesFactor -> array
    Execution halted
Flavor: r-devel-osx-x86_64-clang

Version: 1.3-3
Check: running examples for arch ‘i386’
Result: ERROR
    Running examples in 'MCMCpack-Ex.R' failed
    The error most likely occurred in:
    
    > ### Name: MCMCoprobitChange
    > ### Title: Markov Chain Monte Carlo for Ordered Probit Changepoint
    > ### Regression Model
    > ### Aliases: MCMCoprobitChange
    > ### Keywords: models
    >
    > ### ** Examples
    >
    > set.seed(1909)
    > N <- 200
    > x1 <- rnorm(N, 1, .5);
    >
    > ## set a true break at 100
    > z1 <- 1 + x1[1:100] + rnorm(100);
    > z2 <- 1 -0.2*x1[101:200] + rnorm(100);
    > z <- c(z1, z2);
    > y <- z
    >
    > ## generate y
    > y[z < 1] <- 1;
    > y[z >= 1 & z < 2] <- 2;
    > y[z >= 2] <- 3;
    >
    > ## inputs
    > formula <- y ~ x1
    >
    > ## fit multiple models with a varying number of breaks
    > out1 <- MCMCoprobitChange(formula, m=1,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.30200
    
    
     Acceptance rate for state 2 is 0.33400
    
     The number of observations in state 1 is 00103
     The number of observations in state 2 is 00097
     beta 0 = 0.25560 0.53118
     beta 1 = -0.09097 0.13030
     gamma 0 = 0.79054
     gamma 1 = 1.14920
    logmarglike = -220.04555
    loglike = -192.47056
    log_prior = -4.31181
    log_beta = 4.28397
    log_P = 3.68247
    log_gamma = 15.29673
    > out2 <- MCMCoprobitChange(formula, m=2,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.53400
    
    
     Acceptance rate for state 2 is 0.86800
    
    
     Acceptance rate for state 3 is 0.22400
    
     The number of observations in state 1 is 00107
     The number of observations in state 2 is 00001
     The number of observations in state 3 is 00092
     beta 0 = 0.13360 0.70828
     beta 1 = 0.22094 -0.47864
     beta 2 = 0.40736 -0.28520
     gamma 0 = 0.66271
     gamma 1 = 5.38704
     gamma 2 = 1.34721
    logmarglike = nan
    loglike = -197.66532
    log_prior = -7.77053
    log_beta = 2.66114
    log_P = 4.99484
    log_gamma = nan
    > out3 <- MCMCoprobitChange(formula, m=3,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.24000
    
    
     Acceptance rate for state 2 is 0.87600
    
    
     Acceptance rate for state 3 is 0.64700
    
    
     Acceptance rate for state 4 is 0.48900
    
     The number of observations in state 1 is 00102
     The number of observations in state 2 is 00003
     The number of observations in state 3 is 00008
     The number of observations in state 4 is 00087
     beta 0 = -0.08525 0.82141
     beta 1 = 0.15273 -0.06258
     beta 2 = -0.24026 -0.10814
     beta 3 = -0.49359 0.31134
     gamma 0 = 0.95969
     gamma 1 = 1.49675
     gamma 2 = 23.05777
     gamma 3 = 0.88755
    logmarglike = nan
    loglike = -195.16891
    log_prior = -10.05154
    log_beta = 4.60715
    log_P = 5.73137
    log_gamma = nan
    >
    > ## find the most reasonable one
    > BayesFactor(out1, out2, out3)
    Error in array(NA, M, dimnames = model.names) : 'dimnames' must be a list
    Calls: BayesFactor -> array
    Execution halted
Flavor: r-devel-windows-ix86+x86_64

Version: 1.3-3
Check: running examples for arch ‘x64’
Result: ERROR
    Running examples in 'MCMCpack-Ex.R' failed
    The error most likely occurred in:
    
    > ### Name: MCMCoprobitChange
    > ### Title: Markov Chain Monte Carlo for Ordered Probit Changepoint
    > ### Regression Model
    > ### Aliases: MCMCoprobitChange
    > ### Keywords: models
    >
    > ### ** Examples
    >
    > set.seed(1909)
    > N <- 200
    > x1 <- rnorm(N, 1, .5);
    >
    > ## set a true break at 100
    > z1 <- 1 + x1[1:100] + rnorm(100);
    > z2 <- 1 -0.2*x1[101:200] + rnorm(100);
    > z <- c(z1, z2);
    > y <- z
    >
    > ## generate y
    > y[z < 1] <- 1;
    > y[z >= 1 & z < 2] <- 2;
    > y[z >= 2] <- 3;
    >
    > ## inputs
    > formula <- y ~ x1
    >
    > ## fit multiple models with a varying number of breaks
    > out1 <- MCMCoprobitChange(formula, m=1,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.30200
    
    
     Acceptance rate for state 2 is 0.33400
    
     The number of observations in state 1 is 00103
     The number of observations in state 2 is 00097
     beta 0 = 0.25560 0.53118
     beta 1 = -0.09097 0.13030
     gamma 0 = 0.79054
     gamma 1 = 1.14920
    logmarglike = -220.04555
    loglike = -192.47056
    log_prior = -4.31181
    log_beta = 4.28397
    log_P = 3.68247
    log_gamma = 15.29673
    > out2 <- MCMCoprobitChange(formula, m=2,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.53400
    
    
     Acceptance rate for state 2 is 0.86800
    
    
     Acceptance rate for state 3 is 0.22400
    
     The number of observations in state 1 is 00107
     The number of observations in state 2 is 00001
     The number of observations in state 3 is 00092
     beta 0 = 0.13360 0.70828
     beta 1 = 0.22094 -0.47864
     beta 2 = 0.40736 -0.28520
     gamma 0 = 0.66271
     gamma 1 = 5.38704
     gamma 2 = 1.34721
    logmarglike = nan
    loglike = -197.66532
    log_prior = -7.77053
    log_beta = 2.66115
    log_P = 4.99484
    log_gamma = nan
    > out3 <- MCMCoprobitChange(formula, m=3,
    + mcmc=1000, burnin=1000, thin=1, tune=c(.5, .5, .5, .5), verbose=1000,
    + b0=0, B0=10, marginal.likelihood = "Chib95")
    
    
    MCMCoprobitChange iteration 1001 of 2000
    
    
     Acceptance rate for state 1 is 0.24000
    
    
     Acceptance rate for state 2 is 0.87600
    
    
     Acceptance rate for state 3 is 0.64700
    
    
     Acceptance rate for state 4 is 0.48900
    
     The number of observations in state 1 is 00102
     The number of observations in state 2 is 00003
     The number of observations in state 3 is 00008
     The number of observations in state 4 is 00087
     beta 0 = -0.08525 0.82141
     beta 1 = 0.15273 -0.06258
     beta 2 = -0.24026 -0.10814
     beta 3 = -0.49359 0.31134
     gamma 0 = 0.95969
     gamma 1 = 1.49675
     gamma 2 = 23.05777
     gamma 3 = 0.88755
    logmarglike = nan
    loglike = -195.16892
    log_prior = -10.05155
    log_beta = 4.60715
    log_P = 5.73137
    log_gamma = nan
    >
    > ## find the most reasonable one
    > BayesFactor(out1, out2, out3)
    Error in array(NA, M, dimnames = model.names) : 'dimnames' must be a list
    Calls: BayesFactor -> array
    Execution halted
Flavor: r-devel-windows-ix86+x86_64

Version: 1.3-3
Check: R code for possible problems
Result: NOTE
    plot.qrssvs: no visible global function definition for ‘dotplot’
    plot.qrssvs : <anonymous>: no visible global function definition for
     ‘panel.abline’
    plot.qrssvs : <anonymous>: no visible global function definition for
     ‘panel.dotplot’
Flavors: r-patched-linux-x86_64, r-patched-solaris-sparc, r-patched-solaris-x86, r-release-linux-x86_64, r-release-osx-x86_64-mavericks, r-release-windows-ix86+x86_64, r-oldrel-windows-ix86+x86_64