diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29b..09010966 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + added: + - Default input and output periods to Simulation constructor. diff --git a/policyengine_core/simulations/simulation.py b/policyengine_core/simulations/simulation.py index 472ea636..795642fc 100644 --- a/policyengine_core/simulations/simulation.py +++ b/policyengine_core/simulations/simulation.py @@ -89,7 +89,15 @@ def __init__( dataset: Union[str, Type[Dataset]] = None, reform: Reform = None, trace: bool = False, + default_input_period: str = None, + default_calculation_period: str = None, ): + self.default_input_period = ( + default_input_period or self.default_input_period + ) + self.default_calculation_period = ( + default_calculation_period or self.default_calculation_period + ) if tax_benefit_system is None: if ( self.default_tax_benefit_system_instance is not None