Methods to create or return a SyncroSim Session
.
session(x = NULL, silent = TRUE, printCmd = FALSE)
# S4 method for missingOrNULLOrChar
session(x = NULL, silent = TRUE, printCmd = FALSE)
# S4 method for SsimObject
session(x = NULL, silent = TRUE, printCmd = FALSE)
session(ssimObject) <- value
# S4 method for NULLOrChar
session(ssimObject) <- value
# S4 method for SsimObject
session(ssimObject) <- value
character or SsimObject. Path to SyncroSim installation. If NULL
(default), then default path is used
logical. Applies only if x is a path or NULL
If TRUE
, warnings
from the console are ignored. Otherwise they are printed. Default is FALSE
logical. Applies only if x is a path or NULL
If TRUE
,
arguments passed to the SyncroSim console are also printed. Helpful for
debugging. Default is FALSE
Session
object
A SyncroSim Session
object.
In order to avoid problems with SyncroSim version compatibility and SsimLibrary
updating, the new Session must have the same filepath as the Session of the
SsimObject
e.g. filepath(value)==filepath(session(ssimObject))
.
Therefore, the only time when you will need to set a new SyncroSim Session is if you
have updated the SyncroSim software and want to update an existing SsimObject
to use the new software.
# \donttest{
# Specify file path and name of new SsimLibrary
myLibraryName <- file.path(tempdir(), "testlib")
# Set up a SyncroSim Session, SsimLibrary, and Project
mySession <- session()
myLibrary <- ssimLibrary(name = myLibraryName, session = mySession)
myProject <- project(myLibrary, project = "Definitions")
# Lists the folder location of SyncroSim Session
filepath(mySession)
#> [1] "C:/Program Files/SyncroSim"
# Lists the version of SyncroSim Session
version(mySession)
#> [1] "2.4.27"
# Data frame of the packages installed with this version of SyncroSim
package(mySession)
#> name
#> 1 Name
#> 2 burnp3basemodel
#> 3 burnP3Plus
#> 4 burnP3PlusCell2Fire
#> 5 burnP3PlusPrometheus
#> 6 demosales
#> 7 designer
#> 8 dgsim
#> 9 epi
#> 10 epiModelVocVaccine
#> 11 helloworld
#> 12 helloworldConda
#> 13 helloworldOmni
#> 14 helloworldPipeline
#> 15 helloworldSpatial
#> 16 helloworldSpatialConda
#> 17 helloworldSpatialReports
#> 18 helloworldTime
#> 19 helloworldUncertainty
#> 20 netlogo
#> 21 omniscape
#> 22 prioritizr
#> 23 stsim
#> 24 stsimBurnP3Plus
#> 25 stsimcbmcfs3
#> 26 stsimNestweb
#> 27 stsimpvfc
#> 28 stsimsf
#> 29 wisdm
#> description
#> 1 Description
#> 2 BurnP3 base model
#> 3 Burn-P3+ package for burn probability modeling
#> 4 Cell2Fire fire growth model add-on package for BurnP3+
#> 5 Prometheus fire growth model add-on package for BurnP3+
#> 6 Demo Sales SyncroSim Base Package
#> 7 SyncroSim Package Designer
#> 8 Simulates demographics of wildlife populations
#> 9 Model of epidemic infections and deaths
#> 10 Integrates VOCs and vaccination in the Epi model
#> 11 Example demonstrating how to create a package
#> 12 Example demonstrating how to create a package with Conda environments
#> 13 Example demonstrating how to create a package
#> 14 Example demonstrating how to use pipelines
#> 15 Example demonstrating how to use spatial data
#> 16 Example demonstrating conda environments
#> 17 Example demonstrating how to use spatial data
#> 18 Example demonstrating how to use timesteps
#> 19 Example demonstrating how to use iterations
#> 20 Runs the NetLogo agent-based modeling environment
#> 21 Omni-directional habitat connectivity based on circuit theory
#> 22 Systematic conservation planning
#> 23 The ST-Sim state-and-transition simulation model
#> 24 Incorporates BurnP3+ fire simulations into ST-Sim models
#> 25 Integrates the Carbon Budget Model for the Canadian Forest Sector (CBM-CFS3) into the ST-Sim simulation model.
#> 26 ST-Sim Nestweb
#> 27 Integrates Potential Vegetation Fuels Change (PVFC) for LANDFIRE into the ST-Sim model
#> 28 Integrates stocks and flows into the ST-Sim simulation model
#> 29 Workbench for Integrated Species Distribution Modeling
#> version NA
#> 1 Version Location
#> 2 0.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\burnp3basemodel
#> 3 0.4.3 C:\\Users\\birch\\SyncroSim\\Packages\\burnP3Plus
#> 4 0.4.4 C:\\Users\\birch\\SyncroSim\\Packages\\burnP3PlusCell2Fire
#> 5 0.4.4 C:\\Users\\birch\\SyncroSim\\Packages\\burnP3PlusPrometheus
#> 6 1.1.1 C:\\Users\\birch\\SyncroSim\\Packages\\demosales
#> 7 1.0.14 C:\\Users\\birch\\SyncroSim\\Packages\\designer
#> 8 2.3.3 C:\\Users\\birch\\SyncroSim\\Packages\\dgsim
#> 9 1.1.3 C:\\Users\\birch\\SyncroSim\\Packages\\epi
#> 10 1.0.3 C:\\Users\\birch\\SyncroSim\\Packages\\epiModelVocVaccine
#> 11 1.0.1 C:\\Users\\birch\\SyncroSim\\Packages\\helloworld
#> 12 1.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldConda
#> 13 1.0.1 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldOmni
#> 14 1.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldPipeline
#> 15 1.0.5 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldSpatial
#> 16 1.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldSpatialConda
#> 17 1.0.3 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldSpatialReports
#> 18 1.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldTime
#> 19 1.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\helloworldUncertainty
#> 20 1.2.1 C:\\Users\\birch\\SyncroSim\\Packages\\netlogo
#> 21 1.0.1 C:\\Users\\birch\\SyncroSim\\Packages\\omniscape
#> 22 1.0.0 C:\\Users\\birch\\SyncroSim\\Packages\\prioritizr
#> 23 3.3.13 C:\\Users\\birch\\SyncroSim\\Packages\\stsim
#> 24 1.0.2 C:\\Users\\birch\\SyncroSim\\Packages\\stsimBurnP3Plus
#> 25 1.0.17 C:\\Users\\birch\\SyncroSim\\Packages\\stsimcbmcfs3
#> 26 1.0.0 C:\\gitprojects\\stsimNestweb
#> 27 1.0.2 C:\\Users\\birch\\SyncroSim\\Packages\\stsimpvfc
#> 28 3.3.13 C:\\Users\\birch\\SyncroSim\\Packages\\stsimsf
#> 29 1.0.9 C:\\Users\\birch\\SyncroSim\\Packages\\wisdm
#> NA
#> 1 Status
#> 2 OK
#> 3 OK
#> 4 OK
#> 5 OK
#> 6 OK
#> 7 OK
#> 8 OK
#> 9 OK
#> 10 OK
#> 11 OK
#> 12 OK
#> 13 OK
#> 14 OK
#> 15 OK
#> 16 OK
#> 17 OK
#> 18 OK
#> 19 OK
#> 20 OK
#> 21 OK
#> 22 OK
#> 23 OK
#> 24 OK
#> 25 OK
#> 26 OK
#> 27 OK
#> 28 OK
#> 29 OK
# Data frame of the base packages installed with this version of SyncroSim
package(mySession, installed = "BASE")
#> name
#> 1 burnP3Plus
#> 2 demosales
#> 3 designer
#> 4 dgsim
#> 5 epi
#> 6 helloworld
#> 7 helloworldConda
#> 8 helloworldOmni
#> 9 helloworldPipeline
#> 10 helloworldSpatial
#> 11 helloworldSpatialConda
#> 12 helloworldSpatialReports
#> 13 helloworldTime
#> 14 helloworldUncertainty
#> 15 netlogo
#> 16 omniscape
#> 17 prioritizr
#> 18 stsim
#> 19 wisdm
#> description
#> 1 Burn-P3+ package for burn probability modeling
#> 2 Demo Sales SyncroSim Base Package
#> 3 SyncroSim Package Designer
#> 4 Simulates demographics of wildlife populations
#> 5 Model of epidemic infections and deaths
#> 6 Example demonstrating how to create a package
#> 7 Example demonstrating how to create a package with Conda environments
#> 8 Example demonstrating how to create a package
#> 9 Example demonstrating how to use pipelines
#> 10 Example demonstrating how to use spatial data
#> 11 Example demonstrating conda environments
#> 12 Example demonstrating how to use spatial data
#> 13 Example demonstrating how to use timesteps
#> 14 Example demonstrating how to use iterations
#> 15 Runs the NetLogo agent-based modeling environment
#> 16 Omni-directional habitat connectivity based on circuit theory
#> 17 Systematic conservation planning
#> 18 The ST-Sim state-and-transition simulation model
#> 19 Workbench for Integrated Species Distribution Modeling
#> version
#> 1 0.4.3
#> 2 1.1.1
#> 3 1.0.14
#> 4 2.3.3
#> 5 1.1.3
#> 6 1.0.1
#> 7 1.0.0
#> 8 1.0.1
#> 9 1.0.0
#> 10 1.0.5
#> 11 1.0.0
#> 12 1.0.3
#> 13 1.0.0
#> 14 1.0.0
#> 15 1.2.1
#> 16 1.0.1
#> 17 1.0.0
#> 18 3.3.13
#> 19 1.0.9
# Set a new SyncroSim Session for the SyncroSim Project
session(myProject) <- session(x = filepath(session(myProject)))
# }