Running examples in 'Surrogate-Ex.R' failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: plot SPF BinBin
> ### Title: Plots the surrogate predictive function (SPF) in the
> ###   binary-binary settinf.
> ### Aliases: 'plot SPF BinBin' plot.SPF.BinBin
> ### Keywords: Plot SPF Causal-Inference framework Sensitivity
> 
> ### ** Examples
> 
> # Generate plausible values for Pi  
> ICA <- ICA.BinBin.Grid.Sample(pi1_1_=0.341, pi0_1_=0.119,
+ pi1_0_=0.254, pi_1_1=0.686, pi_1_0=0.088, pi_0_1=0.078, Seed=1,
+ Monotonicity=c("General"), M=2500)
>            
> # Compute the surrogate predictive function (SPF)
> SPF <- SPF.BinBin(ICA)
> 
> # Explore the results
> summary(SPF)

Function call:

SPF.BinBin(x = ICA)


Total number of valid Pi vectors
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1657


SPF Descriptives
~~~~~~~~~~~~~~~~
r_min1_min1 	   Mean: 0.33774;  Median: 0.23893;  Mode: 0.22325;  SD: 0.20001
                       Min: 0.20637; Max: 0.56793; 95% CI = [0.208; 0.55148]

r_0_min1    	   Mean: 0.7638;  Median: 0.80468;  Mode: 0.88585;  SD: 0.20487
                       Min: 0.1645; Max: 0.99803; 95% CI = [0.31746; 0.99654]

r_1_min1    	   Mean: 0.21874;  Median: 0.15386;  Mode: 0.096673;  SD: 0.19932
                       Min: 0.0019727; Max: 0.8355; 95% CI = [0.0034601; 0.68254]

r_min1_0    	   Mean: 0.12549;  Median: 0.11943;  Mode: 0.12084;  SD: 0.054858
                       Min: 0.019299; Max: 0.25056; 95% CI = [0.027607; 0.22829]

r_0_0       	   Mean: 0.8258;  Median: 0.82437;  Mode: 0.8191;  SD: 0.051995
                       Min: 0.51251; Max: 0.99108; 95% CI = [0.74516; 0.91928]

r_1_0       	   Mean: 0.1717;  Median: 0.17511;  Mode: 0.18117;  SD: 0.046482
                       Min: 0.0089193; Max: 0.29386; 95% CI = [0.080719; 0.24978]

r_min1_1    	   Mean: 0.066977;  Median: 0.050907;  Mode: 0.031748;  SD: 0.053987
                       Min: 0.0034163; Max: 0.19337; 95% CI = [0.0056882; 0.18861]

r_0_1       	   Mean: 0.79855;  Median: 0.80845;  Mode: 0.82253;  SD: 0.11321
                       Min: 0.12162; Max: 0.99995; 95% CI = [0.58268; 0.98072]

r_1_1       	   Mean: 0.20011;  Median: 0.1915;  Mode: 0.17702;  SD: 0.10936
                       Min: 4.6982e-05; Max: 0.77614; 95% CI = [0.019276; 0.41495] 
> 
> # Examples of plots 
> plot(SPF, Type="All.Histograms")
> plot(SPF, Type="All.Densities")
> plot(SPF, Type="Histogram", Specific.Pi="r_0_0")
> plot(SPF, Type="Box.Plot", Legend.Pos="topleft", Legend.Cex=.7)
Error in boxplot.default(split(mf[[response]], mf[-response], drop = drop,  : 
  invalid first argument
Calls: plot ... boxplot -> boxplot.formula -> boxplot -> boxplot.default
Execution halted