Skip to content

Commit

Permalink
added skip.assign option to sim.outer.tree
Browse files Browse the repository at this point in the history
  • Loading branch information
ArtPoon committed Jul 25, 2020
1 parent 9e9b1d3 commit ae05f46
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion R/simOuterTree.R
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ load.outer.tree <- function(model) {
#'
#' @seealso load.outer.tree
#' @export
sim.outer.tree <- function(model, max.attempts=5) {
sim.outer.tree <- function(model, max.attempts=5, skip.assign=F) {
attempt <- 1

while (attempt <= max.attempts) {
Expand All @@ -228,6 +228,9 @@ sim.outer.tree <- function(model, max.attempts=5) {

# sample events based on population dynamics and rates
events <- .sample.outer.events(run)
if (skip.assign) {
return(events)
}

# assign events only to history of sampled Compartments
resolved <- .assign.events(run, events)
Expand Down

0 comments on commit ae05f46

Please sign in to comment.