StaticUniverseModel#

tradeexecutor.strategy.universe_model.StaticUniverseModel Python class in Trading Strategy framework.

class StaticUniverseModel[source]#

Bases: UniverseModel

Universe that never changes and all assets are in in-process memory.

Only useful for testing, because - any real trading pair universe is deemed to change - trade executor is deemed to go down and up again

__init__(universe)[source]#
Parameters:

universe (StrategyExecutionUniverse) –

Methods

__init__(universe)

check_data_age(ts, universe, ...)

Check if our data is up-to-date and we do not have issues with feeds.

construct_universe(ts, live, universe_options)

Always return the same universe copy - there is no refresh.

preload_universe(universe_options)

Triggered before backtesting execution.

__init__(universe)[source]#
Parameters:

universe (StrategyExecutionUniverse) –

construct_universe(ts, live, universe_options)[source]#

Always return the same universe copy - there is no refresh.

Parameters:
Return type:

StrategyExecutionUniverse