Running examples in ‘Markovchart-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: Markovchart
> ### Title: Cost-efficient X-bar control charts with fixed/random shift
> ###   size, random repair and random sampling time.
> ### Aliases: Markovchart
> ### Keywords: Markov chain control chart
> 
> ### ** Examples
> 
> #Defining parallel_opt parallel settings.
> #parallel_opt can also be left empty to be defined automatically by the function.
> require(parallel)
Loading required package: parallel
> num_workers <-  min(c(detectCores(),2))
> parall	    <-  list(cl=makeCluster(num_workers), forward=FALSE, loginfo=TRUE)
> 
> 
> #Fixed shift size (essentially Duncan's cycle model) - no optimisation.
> stat_deg <- Markovstat(shiftfun="deg", h=1, k=1, sigma=1, s=0.2, delta=2.5)
> res1     <- Markovchart(statdist=stat_deg, cs=1, crparams=20, coparams=50)
> res1
$Results
   G-value Expected cost Cost sd due to process var. 2nd process moment
1 12.40682      12.40682                    18.14134           483.0373
  3rd process moment 4th process moment
1           21268.82           972450.5

$Subcosts
  In-control cost False-alarm cost Out-of-control cost True-alarm cost
1               1         2.564637           0.6405403         8.20164

$Parameters
  Time between samplings (h) Critical value (k)
1                          1                  1

> #Exponential shift - with optimisation - default cost functions.
> stat_exp2 <- Markovstat(shiftfun="exp", h=1, k=1, sigma=1, s=0.2, delta=2,
+                         RanRep=TRUE, alpha=1, beta=3, Vd=30, V=18)
> parall    <- list(cl=makeCluster(num_workers), forward=FALSE, loginfo=TRUE)
> res4      <- Markovchart(statdist=stat_exp2, OPTIM=TRUE, p=0.9, cs=1,
+                          coparams=c(10,3), crparams=c(1,2), vcoparams=c(8,1.5),
+                          vcrparams=c(5,2), parallel_opt=parall)
Error in checkForRemoteErrors(val) : 
  one node produced an error: object 'Markovstat' not found
Calls: Markovchart ... clusterApply -> staticClusterApply -> checkForRemoteErrors
Execution halted