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

> ### Name: summary.OTC
> ### Title: Summary method for optimal testing configuration results
> ### Aliases: summary.OTC
> 
> ### ** Examples
> 
> # Find the optimal testing configuration for
> #   non-informative two-stage hierarchical testing.
> res1 <- OTC1(algorithm = "D2", p = 0.01, Se = 0.99, Sp = 0.99,
+              group.sz = 2:100, obj.fn = c("ET", "MAR", "GR1"),
+              weights = matrix(data = c(1,1), nrow = 1, ncol = 2))
Initial Group Size = 2
Initial Group Size = 3
Initial Group Size = 4
Initial Group Size = 5
Initial Group Size = 6
Initial Group Size = 7
Initial Group Size = 8
Initial Group Size = 9
Initial Group Size = 10
Initial Group Size = 11
Initial Group Size = 12
Initial Group Size = 13
Initial Group Size = 14
Initial Group Size = 15
Initial Group Size = 16
Initial Group Size = 17
Initial Group Size = 18
Initial Group Size = 19
Initial Group Size = 20
Initial Group Size = 21
Initial Group Size = 22
Initial Group Size = 23
Initial Group Size = 24
Initial Group Size = 25
Initial Group Size = 26
Initial Group Size = 27
Initial Group Size = 28
Initial Group Size = 29
Initial Group Size = 30
Initial Group Size = 31
Initial Group Size = 32
Initial Group Size = 33
Initial Group Size = 34
Initial Group Size = 35
Initial Group Size = 36
Initial Group Size = 37
Initial Group Size = 38
Initial Group Size = 39
Initial Group Size = 40
Initial Group Size = 41
Initial Group Size = 42
Initial Group Size = 43
Initial Group Size = 44
Initial Group Size = 45
Initial Group Size = 46
Initial Group Size = 47
Initial Group Size = 48
Initial Group Size = 49
Initial Group Size = 50
Initial Group Size = 51
Initial Group Size = 52
Initial Group Size = 53
Initial Group Size = 54
Initial Group Size = 55
Initial Group Size = 56
Initial Group Size = 57
Initial Group Size = 58
Initial Group Size = 59
Initial Group Size = 60
Initial Group Size = 61
Initial Group Size = 62
Initial Group Size = 63
Initial Group Size = 64
Initial Group Size = 65
Initial Group Size = 66
Initial Group Size = 67
Initial Group Size = 68
Initial Group Size = 69
Initial Group Size = 70
Initial Group Size = 71
Initial Group Size = 72
Initial Group Size = 73
Initial Group Size = 74
Initial Group Size = 75
Initial Group Size = 76
Initial Group Size = 77
Initial Group Size = 78
Initial Group Size = 79
Initial Group Size = 80
Initial Group Size = 81
Initial Group Size = 82
Initial Group Size = 83
Initial Group Size = 84
Initial Group Size = 85
Initial Group Size = 86
Initial Group Size = 87
Initial Group Size = 88
Initial Group Size = 89
Initial Group Size = 90
Initial Group Size = 91
Initial Group Size = 92
Initial Group Size = 93
Initial Group Size = 94
Initial Group Size = 95
Initial Group Size = 96
Initial Group Size = 97
Initial Group Size = 98
Initial Group Size = 99
Initial Group Size = 100

 Number of minutes running:  0 
 
> summary(res1)

Algorithm: Non-informative two-stage hierarchical testing 

Optimal testing configuration:
    Stage 1
ET       11
MAR      11
GR1      11

Expected number of tests:
    E(T)  Value
ET  2.24 0.2035
MAR 2.24 0.2037
GR1 2.24 0.2047

E(T) denotes the expected number of tests.
Value denotes the objective function value per individual.

Overall accuracy of the algorithm:
       PSe    PSp   PPPV   PNPV
ET  0.9801 0.9990 0.9052 0.9998
MAR 0.9801 0.9990 0.9052 0.9998
GR1 0.9801 0.9990 0.9052 0.9998

PSe denotes the pooling sensitivity.
PSp denotes the pooling specificity.
PPPV denotes the pooling positive predictive value.
PNPV denotes the pooling negative predictive value.
> 
> # Find the optimal testing configuration for
> #   informative three-stage hierarchical testing
> res2 <- OTC1(algorithm = "ID3", p = 0.025,
+              Se = c(0.95, 0.95, 0.99), Sp = c(0.96, 0.96, 0.98),
+              group.sz = 3:15, obj.fn = c("ET", "MAR"), alpha = 2)
Initial Group Size = 3
Initial Group Size = 4
Initial Group Size = 5
Initial Group Size = 6
Initial Group Size = 7
Initial Group Size = 8
Initial Group Size = 9
Initial Group Size = 10
Initial Group Size = 11
Initial Group Size = 12
Initial Group Size = 13
Initial Group Size = 14
Initial Group Size = 15

 Number of minutes running:  0.01 
 
> summary(res2)

Algorithm: Informative three-stage hierarchical testing 

Optimal testing configuration:
    Stage 1 Stage 2
ET       15 5,4,3,3
MAR      15 5,4,3,3

Expected number of tests:
    E(T)  Value
ET  3.60 0.2400
MAR 3.60 0.2410

E(T) denotes the expected number of tests.
Value denotes the objective function value per individual.

Overall accuracy of the algorithm:
       PSe    PSp   PPPV   PNPV
ET  0.8935 0.9987 0.9465 0.9973
MAR 0.8935 0.9987 0.9465 0.9973

PSe denotes the pooling sensitivity.
PSp denotes the pooling specificity.
PPPV denotes the pooling positive predictive value.
PNPV denotes the pooling negative predictive value.
> 
> # Find the optimal testing configuration for
> #   informative array testing without master pooling.
> res3 <- OTC1(algorithm = "IA2", p = 0.05, alpha = 2,
+              Se = 0.90, Sp = 0.90, group.sz = 2:10,
+              obj.fn = "ET")
Row/Column Size = 2, Array Size = 4
Row/Column Size = 3, Array Size = 9
Row/Column Size = 4, Array Size = 16
Row/Column Size = 5, Array Size = 25
Row/Column Size = 6, Array Size = 36
Row/Column Size = 7, Array Size = 49
Row/Column Size = 8, Array Size = 64
Row/Column Size = 9, Array Size = 81
Row/Column Size = 10, Array Size = 100

 Number of minutes running:  0.01 
 
> summary(res3)

Algorithm: Informative array testing without master pooling 

Optimal testing configuration:
   Row/column size Array size
ET              10        100

Expected number of tests:
    E(T)  Value
ET 38.00 0.3800

E(T) denotes the expected number of tests.
Value denotes the objective function value per individual.

Overall accuracy of the algorithm:
      PSe    PSp   PPPV   PNPV
ET 0.7303 0.9853 0.7237 0.9858

PSe denotes the pooling sensitivity.
PSp denotes the pooling specificity.
PPPV denotes the pooling positive predictive value.
PNPV denotes the pooling negative predictive value.
> 
> # Find the optimal testing configuraiton for
> #   informative two-stage hierarchical testing.
> Se <- matrix(data = c(rep(0.95, 2), rep(0.99, 2)),
+              nrow = 2, ncol = 2, byrow = FALSE)
> Sp <- matrix(data = c(rep(0.96, 2), rep(0.98, 2)),
+              nrow = 2, ncol = 2, byrow = FALSE)
> res4 <- OTC2(algorithm = "ID2",
+              alpha = c(18.25, 0.75, 0.75, 0.25),
+              Se = Se, Sp = Sp, group.sz = 12)
Block Size = 12

 Number of minutes running:  0.01 
 
> summary(res4)

Algorithm: Informative two-stage hierarchical testing 

Optimal testing configuration:
   Block size Group sizes
ET         12       5,4,3

Expected number of tests:
   E(T)  Value
ET 7.25 0.6045

E(T) denotes the expected number of tests.
Value denotes the objective function value per individual.

Overall accuracy of the algorithm:
     PSe    PSp   PPPV   PNPV
1 0.9705 0.9087 0.3716 0.9982
2 0.9701 0.9076 0.3733 0.9981

PSe denotes the pooling sensitivity.
PSp denotes the pooling specificity.
PPPV denotes the pooling positive predictive value.
PNPV denotes the pooling negative predictive value.
> 
> # Find the optimal testing configuration for
> #   non-informative three-stage hierarchical testing.
> Se <- matrix(data = c(rep(0.95, 6)), nrow = 2, ncol = 3)
> Sp <- matrix(data = c(rep(0.99, 6)), nrow = 2, ncol = 3)
> res5 <- OTC2(algorithm = "D3",
+              p.vec = c(0.95, 0.0275, 0.0175, 0.005),
+              Se = Se, Sp = Sp, group.sz = 5:10)
Error in OTC2(algorithm = "D3", p.vec = c(0.95, 0.0275, 0.0175, 0.005),  : 
  Please specify joint probabilities that sum to 1.
Execution halted