SEMSimulation: SEM Simulation

View source: R/Source_Parameters_and_Simulation.R

SEMSimulationR Documentation

SEM Simulation

Description

A wrapper that conveniently handles data saving and times the simulation

Usage

SEMSimulation(P, type = "Basic", folderName = NA, save = TRUE,
  return = FALSE, verbose = TRUE, ...)

Arguments

P

a list of parameters

type

what type of simulation to run ('Basic', 'Light', 'Insult)

folderName

where to save the simualtion data, defaults to a timestemp in the current directory

save

whether to write the data to .csvs

return

whether to return the data in R

verbose

whether to print the running time and folder name

...

arguments to the simulation types. See documentation for individual sim type arguments.

See Also

Other Sim Functions: BasicSimulation, CheckInsultPs, CheckInvasion, GetSaveInfo, InsultSimulation, InvasionSimulation, LightSimulation

Examples

P <- DefineParameters(RepSizePrefer = 0, MatchPrefer = 1, numSim=100)
SEMSimulation(P, 'Basic', 'Example', return=TRUE)
SEMSimulation(P, 'Interval', 'Example', return=TRUE, freq=2)

P2 <- DefineParameters(numSim=600, MatchPrefer = 1, RepSizePrefer = 0)
P3 <- DefineParameters(numSim=600, SaveMatch = TRUE)
SEMSimulation(P2, insultP=P3, 'Insult', when=100, freq=2, save=FALSE, return = TRUE)

NeuroBio/SEM_R_Package documentation built on April 24, 2022, 5:54 p.m.