Skip to content

Commit

Permalink
Merge 7651967 into d8ad0ae
Browse files Browse the repository at this point in the history
  • Loading branch information
alubbock committed Oct 19, 2018
2 parents d8ad0ae + 7651967 commit 061f47a
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions pysb/simulator/bng.py
Expand Up @@ -25,7 +25,7 @@ def __init__(self, model, tspan=None, cleanup=True, verbose=False):

def run(self, tspan=None, initials=None, param_values=None, n_runs=1,
method='ssa', output_dir=None, output_file_basename=None,
cleanup=True, population_maps=None, **additional_args):
cleanup=None, population_maps=None, **additional_args):
"""
Simulate a model using BioNetGen
Expand Down Expand Up @@ -67,8 +67,9 @@ def run(self, tspan=None, initials=None, param_values=None, n_runs=1,
output directory, rather than the individual files.
cleanup : bool, optional
If True (default), delete the temporary files after the
simulation is
finished. If False, leave them in place. Useful for debugging.
simulation is finished. If False, leave them in place (Useful for
debugging). The default value, None, means to use the value
specified in :py:func:`__init__`.
population_maps: list of PopulationMap
List of :py:class:`PopulationMap` objects for hybrid
particle/population modeling. Only used when method='nf'.
Expand All @@ -94,6 +95,9 @@ def run(self, tspan=None, initials=None, param_values=None, n_runs=1,
_run_kwargs=locals()
)

if cleanup is None:
cleanup = self.cleanup

if method not in self._SIMULATOR_TYPES:
raise ValueError("Method must be one of " +
str(self._SIMULATOR_TYPES))
Expand Down

0 comments on commit 061f47a

Please sign in to comment.