DailyMarketEvent

class qf_lib.backtesting.events.time_event.regular_time_event.daily_market_event.DailyMarketEvent[source]

Bases: qf_lib.backtesting.events.time_event.regular_time_event.regular_time_event.RegularTimeEvent

Class implementing the logic for all events happening every day such as MarketOpenEvent, MarketCloseEvent etc. The time has to be set up by calling set_trigger_time before being able to run the backtest.

Methods

trigger_time()

Returns the RelativeDelta which describes at what time the RegularTimeEvent occurs (e.g.

classmethod trigger_time() → qf_lib.common.utils.dateutils.relative_delta.RelativeDelta[source]

Returns the RelativeDelta which describes at what time the RegularTimeEvent occurs (e.g. RelativeDelta(hour=16, minute=0, second=0, milisecond=0) for an event which occurs every day at 16:00).