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

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: read.doe.lsd
> ### Title: Read a set of experimental data from a LSD model
> ### Aliases: read.doe.lsd
> ### Keywords: interface file datasets datagen design
> 
> ### ** Examples
> 
> # get the example directory name
> path <- system.file( "extdata/sobol", package = "LSDsensitivity" )
> 
> # Steps to use this function:
> # 1. define the variables you want to use in the analysis
> # 2. optionally, define special handling functions (see examples below)
> # 3. load data from a LSD simulation saved results using read.doe.lsd
> # 4. perform the elementary effects analysis applying elementary.effects.lsd
> 
> # the definition of existing, to take log and to be added variables
> lsdVars <- c( "var1", "var2", "var3" )
> logVars <- c( "var1", "var3" )
> newVars <- c( "var4" )
> 
> # load data from a LSD simulation baseline configuration named "Sim1.lsd" to
> # perform sensitivity analysis on the variable named "var1"
> # there are two groups of sampled data (DoEs) created by LSD being read
> # just use no handling functions for now, see possible examples below
> dataSet <- read.doe.lsd( path,                 # data files folder
+                          "Sim3",               # data files base name (same as .lsd file)
+                          "var3",               # variable name to perform the sens. analysis
+                          does = 2,             # # of experiments (data + external validation)
+                          iniDrop = 0,          # initial time steps to drop (0=none)
+                          nKeep = -1,           # number of time steps to keep (-1=all)
+                          saveVars = lsdVars,   # LSD variables to keep in dataset
+                          addVars = newVars,    # new variables to add to the LSD dataset
+                          rm.temp = FALSE,      # reuse temporary speedup files
+                          rm.outl = FALSE,      # remove outliers from dataset
+                          lim.outl = 10 )       # limit non-outliers deviation (# of std. devs.)
> 
> #### OPTIONAL HANDLING FUNCTION EXAMPLES ####
> 
> # eval.vars( ) EXAMPLE 1
> # the definition of a function to take the log of the required variables () and
> # compute the new ones (for use on pool = TRUE databases)
> 
> eval.vars <- function( dataSet, allVars ) {
+   tsteps <- nrow( dataSet )        # number of time steps in simulated data set
+   nvars <- ncol( dataSet )         # number of variables in data set (including new ones)
+ 
+   # ---- Recompute values for existing variables ----
+   for( var in allVars ) {
+     if( var %in% logVars ) {     # take the log values of selected variables
+       try( dataSet[ , var ] <- log( dataSet[ , var ] ), silent = TRUE )  # <= 0 as NaN
+     }
+   }
+ 
+   # ---- Calculate values of new variables (added to LSD data set) ----
+   dataSet[ , "var4" ] <- dataSet[ , "var1" ] + dataSet[ , "var2" ]   # example of new var
+ 
+   return( dataSet )
+ }
> 
> # load data again, now using new variable v4 for analysis
> dataSet <- read.doe.lsd( path,                 # data files folder
+                          "Sim3",               # data files base name (same as .lsd file)
+                          "var4",               # variable name to perform the sens. analysis
+                          does = 2,             # # of experiments (data + external validation)
+                          iniDrop = 0,          # initial time steps to drop (0=none)
+                          nKeep = -1,           # number of time steps to keep (-1=all)
+                          saveVars = lsdVars,   # LSD variables to keep in dataset
+                          addVars = newVars,    # new variables to add to the LSD dataset
+                          eval.vars = eval.vars,# function to evaluate/adjust/expand the dataset
+                          rm.temp = TRUE,       # remove temporary speedup files
+                          rm.outl = FALSE,      # remove outliers from dataset
+                          lim.outl = 10 )       # limit non-outliers deviation (# of std. devs.)
Error in value[[3L]](cond) : 
  Cannot write DoE response file to disk (read-only?)
Calls: read.doe.lsd ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted