Running ‘testthat.R’ [265s/371s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > test_check("BMhyb")
  Loading required package: BMhyb
  [1] "Now starting analysis"
  [1] "Starting with initial values"
     sigma.sq          mu          SE          bt          vh 
  0.117682960 2.118832288 0.007956494 1.000000000 0.007956494 
    Nelder-Mead direct search function minimizer
  function value for initial parameters = 24.088800
    Scaled convergence tolerance is 2.41888
  Stepsize computed as 0.211883
  BUILD              6 29.371482 24.088800
  HI-REDUCTION       8 26.889548 24.088800
  Exiting from Nelder Mead minimizer
      10 function evaluations used
          step    negloglik     sigma.sq           mu           SE           bt 
   1.000000000 24.088800143  0.117682960  2.118832288  0.007956494  1.000000000 
            vh 
   0.007956494 
    Nelder-Mead direct search function minimizer
  function value for initial parameters = 24.088800
    Scaled convergence tolerance is 2.41888
  Stepsize computed as 0.211883
  BUILD              6 29.371482 24.088800
  HI-REDUCTION       8 26.889548 24.088800
  Exiting from Nelder Mead minimizer
      10 function evaluations used
          step    negloglik     sigma.sq           mu           SE           bt 
   2.000000000 24.088800143  0.117682960  2.118832288  0.007956494  1.000000000 
            vh 
   0.007956494 
    Nelder-Mead direct search function minimizer
  function value for initial parameters = 24.147180
    Scaled convergence tolerance is 2.42472
  Stepsize computed as 0.209339
  BUILD              6 29.293376 24.147180
  HI-REDUCTION       8 26.841853 24.147180
  Exiting from Nelder Mead minimizer
      10 function evaluations used
          step    negloglik     sigma.sq           mu           SE           bt 
   3.000000000 24.088800143  0.117682960  2.118832288  0.007956494  1.000000000 
            vh 
   0.007956494 
  [1] "100 of 100 done"
  [1] "Now starting analysis"
  [1] "Starting with initial values"
    sigma.sq         mu         SE         bt         vh 
  6.24018057 2.17682605 0.06240181 1.00000000 0.06240181 
    Nelder-Mead direct search function minimizer
  function value for initial parameters = 14.614143
    Scaled convergence tolerance is 1.47141
  Stepsize computed as 0.624018
  BUILD              6 14.614143 12.428065
  LO-REDUCTION       8 14.483439 12.428065
  EXTENSION         10 14.235052 11.624060
  EXTENSION         12 13.364881 10.776878
  REFLECTION        14 12.853160 10.658525
  LO-REDUCTION      16 12.502150 10.658525
  EXTENSION         18 12.428065 10.238413
  Exiting from Nelder Mead minimizer
      20 function evaluations used
         step   negloglik    sigma.sq          mu          SE          bt 
   1.00000000 10.23841251  5.57946027 -0.06899996  0.78550395  2.98112254 
           vh 
   1.14493835 
    Nelder-Mead direct search function minimizer
  function value for initial parameters = 10.238413
    Scaled convergence tolerance is 1.03384
  Stepsize computed as 0.557946
  Exiting from Nelder Mead minimizer
      6 function evaluations used
  [1] "New improvement found, resetting step counter"
         step   negloglik    sigma.sq          mu          SE          bt 
   2.00000000  9.95074424  5.57946027 -0.06899996  0.78550395  3.53906857 
           vh 
   1.14493835 
    Nelder-Mead direct search function minimizer
  ── 1. Error: Simulation works (@test_condition.R#31)  ──────────────────────────
  non-finite value supplied by optim
  Backtrace:
   1. BMhyb::BMhyb(...)
   2. BMhyb:::OptimizeThoroughly(...)
   3. stats::optim(...)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 12 | SKIPPED: 0 | WARNINGS: 6 | FAILED: 1 ]
  1. Error: Simulation works (@test_condition.R#31) 
  
  Error: testthat unit tests failed
  Execution halted