Deliver geospatial models direct to decision makers with SyncroSim › Forums › SyncroSim – General Questions and Answers › Rsyncrosim inability to access scenarios › Reply To: Rsyncrosim inability to access scenarios
One thing that would cause the problem you describe is if you are using an incorrect folder/filename for the library you are trying to reopen. The ssimLibrary() function will either open an existing library (if it exists) or alternatively create a new blank library (if it does not exist). If you get the filename wrong then you will create a new empty library when you first call ssimLibrary(). Every subsequent call to ssimLibrary() will then continue to open this empty library.
You can try this code to test where SyncroSim is looking for your library:
library(rsyncrosim)
getwd() # check to see your current working folder
addPackage("stsim") # make sure you have the package you wish to use installed
# Next line will either open test.ssim (if it exists in the working folder) OR
# create a new empty library (if it does not exist)
myLibrary = ssimLibrary("test.ssim", package = "stsim")
list.files(getwd()) # see the new test.ssim file that was created or opened