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

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: spread2
> ### Title: Simulate a contagious spread process on a landscape, with
> ###   data.table internals
> ### Aliases: spread2
> 
> ### ** Examples
> 
> library(data.table)
> library(raster)
Loading required package: sp
> library(quickPlot)
> 
> data.table::setDTthreads(1)
> 
> a <- raster(extent(0, 10, 0, 10), res = 1)
> sams <- sort(sample(ncell(a), 3))
> 
> # Simple use -- similar to spread(...)
> out <- spread2(a, start = sams, 0.225)
> if (interactive()) {
+   clearPlot()
+   Plot(out)
+ }
> 
> # Use maxSize -- this gives an upper limit
> maxSizes <- sort(sample(1:10, size = length(sams)))
> out <- spread2(a, start = sams, 0.225, maxSize = maxSizes, asRaster = FALSE)
Error: $ operator is invalid for atomic vectors
Execution halted
Running 'test-all.R' [70s/90s]
Running the tests in 'tests/test-all.R' failed.
Complete output:
  > library(testthat)
  > test_check("SpaDES.tools")
  Loading required package: SpaDES.tools
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  
  == Skipped tests ===============================================================
  * DEoptim within spread2 (1)
  * On CRAN (3)
  * dqrnq cannot be loaded (2)
  * empty test (1)
  
  == Failed tests ================================================================
  -- Error (test-spread2.R:57:5): spread2 tests ----------------------------------
  Error: $ operator is invalid for atomic vectors
  Backtrace:
      x
   1. \-SpaDES.tools::spread2(...) at test-spread2.R:57:4
   2.   +-dt[-dt1a$omit]
   3.   \-data.table:::`[.data.table`(dt, -dt1a$omit)
   4.     \-base::tryCatch(...)
   5.       \-base tryCatchList(expr, classes, parentenv, handlers)
   6.         \-base tryCatchOne(expr, names, parentenv, handlers[[1L]])
   7.           \-value[[3L]](cond)
   8.             \-data.table:::.checkTypos(e, names_x)
  
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  Error: Test failures
  Execution halted
Running examples in ‘SpaDES.tools-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: spread2
> ### Title: Simulate a contagious spread process on a landscape, with
> ###   data.table internals
> ### Aliases: spread2
> 
> ### ** Examples
> 
> library(data.table)
> library(raster)
Loading required package: sp
> library(quickPlot)
> 
> data.table::setDTthreads(1)
> 
> a <- raster(extent(0, 10, 0, 10), res = 1)
> sams <- sort(sample(ncell(a), 3))
> 
> # Simple use -- similar to spread(...)
> out <- spread2(a, start = sams, 0.225)
> if (interactive()) {
+   clearPlot()
+   Plot(out)
+ }
> 
> # Use maxSize -- this gives an upper limit
> maxSizes <- sort(sample(1:10, size = length(sams)))
> out <- spread2(a, start = sams, 0.225, maxSize = maxSizes, asRaster = FALSE)
Error: $ operator is invalid for atomic vectors
Execution halted
Running ‘test-all.R’ [50s/94s]
Running the tests in ‘tests/test-all.R’ failed.
Complete output:
  > library(testthat)
  > test_check("SpaDES.tools")
  Loading required package: SpaDES.tools
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • DEoptim within spread2 (1)
  • On CRAN (3)
  • dqrnq cannot be loaded (2)
  • empty test (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-spread2.R:57:5): spread2 tests ──────────────────────────────────
  Error: $ operator is invalid for atomic vectors
  Backtrace:
      ▆
   1. └─SpaDES.tools::spread2(...) at test-spread2.R:57:4
   2.   ├─dt[-dt1a$omit]
   3.   └─data.table:::`[.data.table`(dt, -dt1a$omit)
   4.     └─base::tryCatch(...)
   5.       └─base tryCatchList(expr, classes, parentenv, handlers)
   6.         └─base tryCatchOne(expr, names, parentenv, handlers[[1L]])
   7.           └─value[[3L]](cond)
   8.             └─data.table:::.checkTypos(e, names_x)
  
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  Error: Test failures
  Execution halted
Running examples in ‘SpaDES.tools-Ex.R’ failed
The error most likely occurred in:

> ### Name: spread2
> ### Title: Simulate a contagious spread process on a landscape, with
> ###   data.table internals
> ### Aliases: spread2
> 
> ### ** Examples
> 
> library(data.table)
> library(raster)
Loading required package: sp
> library(quickPlot)
> 
> data.table::setDTthreads(1)
> 
> a <- raster(extent(0, 10, 0, 10), res = 1)
> sams <- sort(sample(ncell(a), 3))
> 
> # Simple use -- similar to spread(...)
> out <- spread2(a, start = sams, 0.225)
> if (interactive()) {
+   clearPlot()
+   Plot(out)
+ }
> 
> # Use maxSize -- this gives an upper limit
> maxSizes <- sort(sample(1:10, size = length(sams)))
> out <- spread2(a, start = sams, 0.225, maxSize = maxSizes, asRaster = FALSE)
Error: $ operator is invalid for atomic vectors
Execution halted
Running ‘test-all.R’ [79s/101s]
Running the tests in ‘tests/test-all.R’ failed.
Complete output:
  > library(testthat)
  > test_check("SpaDES.tools")
  Loading required package: SpaDES.tools
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • DEoptim within spread2 (1)
  • On CRAN (3)
  • dqrnq cannot be loaded (2)
  • empty test (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-spread2.R:57:5): spread2 tests ──────────────────────────────────
  Error: $ operator is invalid for atomic vectors
  Backtrace:
      ▆
   1. └─SpaDES.tools::spread2(...) at test-spread2.R:57:4
   2.   ├─dt[-dt1a$omit]
   3.   └─data.table:::`[.data.table`(dt, -dt1a$omit)
   4.     └─base::tryCatch(...)
   5.       └─base tryCatchList(expr, classes, parentenv, handlers)
   6.         └─base tryCatchOne(expr, names, parentenv, handlers[[1L]])
   7.           └─value[[3L]](cond)
   8.             └─data.table:::.checkTypos(e, names_x)
  
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  Error: Test failures
  Execution halted
Running examples in ‘SpaDES.tools-Ex.R’ failed
The error most likely occurred in:

> ### Name: spread2
> ### Title: Simulate a contagious spread process on a landscape, with
> ###   data.table internals
> ### Aliases: spread2
> 
> ### ** Examples
> 
> library(data.table)
> library(raster)
Loading required package: sp
> library(quickPlot)
> 
> data.table::setDTthreads(1)
> 
> a <- raster(extent(0, 10, 0, 10), res = 1)
> sams <- sort(sample(ncell(a), 3))
> 
> # Simple use -- similar to spread(...)
> out <- spread2(a, start = sams, 0.225)
> if (interactive()) {
+   clearPlot()
+   Plot(out)
+ }
> 
> # Use maxSize -- this gives an upper limit
> maxSizes <- sort(sample(1:10, size = length(sams)))
> out <- spread2(a, start = sams, 0.225, maxSize = maxSizes, asRaster = FALSE)
Error: $ operator is invalid for atomic vectors
Execution halted
Running ‘test-all.R’ [81s/103s]
Running the tests in ‘tests/test-all.R’ failed.
Complete output:
  > library(testthat)
  > test_check("SpaDES.tools")
  Loading required package: SpaDES.tools
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • DEoptim within spread2 (1)
  • On CRAN (3)
  • dqrnq cannot be loaded (2)
  • empty test (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-spread2.R:57:5): spread2 tests ──────────────────────────────────
  Error: $ operator is invalid for atomic vectors
  Backtrace:
      ▆
   1. └─SpaDES.tools::spread2(...) at test-spread2.R:57:4
   2.   ├─dt[-dt1a$omit]
   3.   └─data.table:::`[.data.table`(dt, -dt1a$omit)
   4.     └─base::tryCatch(...)
   5.       └─base tryCatchList(expr, classes, parentenv, handlers)
   6.         └─base tryCatchOne(expr, names, parentenv, handlers[[1L]])
   7.           └─value[[3L]](cond)
   8.             └─data.table:::.checkTypos(e, names_x)
  
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  Error: Test failures
  Execution halted
Running examples in 'SpaDES.tools-Ex.R' failed
The error most likely occurred in:

> ### Name: spread2
> ### Title: Simulate a contagious spread process on a landscape, with
> ###   data.table internals
> ### Aliases: spread2
> 
> ### ** Examples
> 
> library(data.table)
> library(raster)
Loading required package: sp
> library(quickPlot)
> 
> data.table::setDTthreads(1)
> 
> a <- raster(extent(0, 10, 0, 10), res = 1)
> sams <- sort(sample(ncell(a), 3))
> 
> # Simple use -- similar to spread(...)
> out <- spread2(a, start = sams, 0.225)
> if (interactive()) {
+   clearPlot()
+   Plot(out)
+ }
> 
> # Use maxSize -- this gives an upper limit
> maxSizes <- sort(sample(1:10, size = length(sams)))
> out <- spread2(a, start = sams, 0.225, maxSize = maxSizes, asRaster = FALSE)
Error: $ operator is invalid for atomic vectors
Execution halted
Running 'test-all.R' [59s]
Running the tests in 'tests/test-all.R' failed.
Complete output:
  > library(testthat)
  > test_check("SpaDES.tools")
  Loading required package: SpaDES.tools
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • DEoptim within spread2 (1)
  • On CRAN (3)
  • dqrnq cannot be loaded (2)
  • empty test (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-spread2.R:57:5): spread2 tests ──────────────────────────────────
  Error: $ operator is invalid for atomic vectors
  Backtrace:
      ▆
   1. └─SpaDES.tools::spread2(...) at test-spread2.R:57:4
   2.   ├─dt[-dt1a$omit]
   3.   └─data.table:::`[.data.table`(dt, -dt1a$omit)
   4.     └─base::tryCatch(...)
   5.       └─base tryCatchList(expr, classes, parentenv, handlers)
   6.         └─base tryCatchOne(expr, names, parentenv, handlers[[1L]])
   7.           └─value[[3L]](cond)
   8.             └─data.table:::.checkTypos(e, names_x)
  
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  Error: Test failures
  Execution halted
Running examples in 'SpaDES.tools-Ex.R' failed
The error most likely occurred in:

> ### Name: spread2
> ### Title: Simulate a contagious spread process on a landscape, with
> ###   data.table internals
> ### Aliases: spread2
> 
> ### ** Examples
> 
> library(data.table)
> library(raster)
Loading required package: sp
> library(quickPlot)
> 
> data.table::setDTthreads(1)
> 
> a <- raster(extent(0, 10, 0, 10), res = 1)
> sams <- sort(sample(ncell(a), 3))
> 
> # Simple use -- similar to spread(...)
> out <- spread2(a, start = sams, 0.225)
> if (interactive()) {
+   clearPlot()
+   Plot(out)
+ }
> 
> # Use maxSize -- this gives an upper limit
> maxSizes <- sort(sample(1:10, size = length(sams)))
> out <- spread2(a, start = sams, 0.225, maxSize = maxSizes, asRaster = FALSE)
Error: $ operator is invalid for atomic vectors
Execution halted
Running 'test-all.R'
Running the tests in 'tests/test-all.R' failed.
Complete output:
  > library(testthat)
  > test_check("SpaDES.tools")
  Loading required package: SpaDES.tools
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • DEoptim within spread2 (1)
  • On CRAN (3)
  • dqrnq cannot be loaded (2)
  • empty test (1)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-spread2.R:57:5): spread2 tests ──────────────────────────────────
  Error: $ operator is invalid for atomic vectors
  Backtrace:
      ▆
   1. └─SpaDES.tools::spread2(...) at test-spread2.R:57:4
   2.   ├─dt[-dt1a$omit]
   3.   └─data.table:::`[.data.table`(dt, -dt1a$omit)
   4.     └─base::tryCatch(...)
   5.       └─base tryCatchList(expr, classes, parentenv, handlers)
   6.         └─base tryCatchOne(expr, names, parentenv, handlers[[1L]])
   7.           └─value[[3L]](cond)
   8.             └─data.table:::.checkTypos(e, names_x)
  
  [ FAIL 1 | WARN 0 | SKIP 7 | PASS 778 ]
  Error: Test failures
  Execution halted