bergant/nlexperiment

Not working with NetLogo versions >= 6.1.0

bachl opened this issue · 0 comments

bachl commented

I re-ran some older code which worked (and still works) just fine with NetLogo 6.0.4. As I had to download NetLogo anyway, I got the latest version (6.1.1). The example from the manual

nl_netlogo_path("/Applications/NetLogo 6.1.1/Java/") 
experiment <- nl_experiment(
  model_file = "/Applications/NetLogo 6.1.1/models/Sample Models/Earth Science/Fire.nlogo", 
  while_condition = "any? turtles",
  param_values = list(density = c(57, 59, 61)),
  random_seed = 1,
  step_measures = measures(
    percent_burned = "(burned-trees / initial-trees) * 100"
  )
)
result <- nl_run(experiment)  

resulted in the error

[1] "Java-Object{java.lang.IllegalStateException: unknown NetLogo version: NetLogo 6.1.1}"

I did not investigate the issue any further, because NetLogo 6.0.4 works fine for me.

> sessionInfo()
R version 3.6.2 (2019-12-12)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.3

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib

locale:
[1] de_DE.UTF-8/de_DE.UTF-8/de_DE.UTF-8/C/de_DE.UTF-8/de_DE.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] nlexperiment_0.2.2.9000

loaded via a namespace (and not attached):
 [1] igraph_1.2.4.2   Rcpp_1.0.3       rstudioapi_0.11  magrittr_1.5     tidyselect_1.0.0 munsell_0.5.0   
 [7] colorspace_1.4-1 R6_2.4.1         rlang_0.4.4      stringr_1.4.0    plyr_1.8.5       dplyr_0.8.4     
[13] tools_3.6.2      grid_3.6.2       packrat_0.5.0    gtable_0.3.0     lazyeval_0.2.2   assertthat_0.2.1
[19] tibble_2.1.3     lifecycle_0.1.0  crayon_1.3.4     RNetLogo_1.0-4   rJava_0.9-11     farver_2.0.3    
[25] reshape2_1.4.3   purrr_0.3.3      ggplot2_3.2.1    glue_1.3.1       labeling_0.3     stringi_1.4.6   
[31] compiler_3.6.2   pillar_1.4.3     scales_1.1.0     pkgconfig_2.0.3