Lean  $LEAN_TAG$
QuantConnect.Securities.FutureFilterUniverse Class Reference

Represents futures symbols universe used in filtering. More...

Inheritance diagram for QuantConnect.Securities.FutureFilterUniverse:
[legend]

Public Member Functions

 FutureFilterUniverse (IEnumerable< Symbol > allSymbols, DateTime localTime)
 Constructs FutureFilterUniverse More...
 
FutureFilterUniverse ExpirationCycle (int[] months)
 Applies filter selecting futures contracts based on expiration cycles. See FutureExpirationCycles for details More...
 
- Public Member Functions inherited from QuantConnect.Securities.ContractSecurityFilterUniverse< FutureFilterUniverse >
virtual void Refresh (IEnumerable< Symbol > allSymbols, DateTime localTime)
 Refreshes this filter universe More...
 
StandardsOnly ()
 Sets universe of standard contracts (if any) as selection Contracts by default are standards; only needed to switch back if changed More...
 
IncludeWeeklys ()
 Includes universe of non-standard weeklys contracts (if any) into selection More...
 
WeeklysOnly ()
 Sets universe of weeklys contracts (if any) as selection More...
 
virtual T FrontMonth ()
 Returns front month contract More...
 
virtual T BackMonths ()
 Returns a list of back month contracts More...
 
BackMonth ()
 Returns first of back month contracts More...
 
virtual T Expiration (TimeSpan minExpiry, TimeSpan maxExpiry)
 Applies filter selecting options contracts based on a range of expiration dates relative to the current day More...
 
Expiration (int minExpiryDays, int maxExpiryDays)
 Applies filter selecting contracts based on a range of expiration dates relative to the current day More...
 
Contracts (PyObject contracts)
 Explicitly sets the selected contract symbols for this universe. This overrides and and all other methods of selecting symbols assuming it is called last. More...
 
Contracts (IEnumerable< Symbol > contracts)
 Explicitly sets the selected contract symbols for this universe. This overrides and and all other methods of selecting symbols assuming it is called last. More...
 
Contracts (Func< IEnumerable< Symbol >, IEnumerable< Symbol >> contractSelector)
 Sets a function used to filter the set of available contract filters. The input to the 'contractSelector' function will be the already filtered list if any other filters have already been applied. More...
 
OnlyApplyFilterAtMarketOpen ()
 Instructs the engine to only filter contracts on the first time step of each market day. More...
 
IEnumerator< SymbolGetEnumerator ()
 IEnumerable interface method implementation More...
 

Protected Member Functions

override bool IsStandard (Symbol symbol)
 Determine if the given Future contract symbol is standard More...
 
- Protected Member Functions inherited from QuantConnect.Securities.ContractSecurityFilterUniverse< FutureFilterUniverse >
 ContractSecurityFilterUniverse ()
 Constructs ContractSecurityFilterUniverse More...
 
 ContractSecurityFilterUniverse (IEnumerable< Symbol > allSymbols, DateTime localTime)
 Constructs ContractSecurityFilterUniverse More...
 

Additional Inherited Members

- Protected Attributes inherited from QuantConnect.Securities.ContractSecurityFilterUniverse< FutureFilterUniverse >
ContractExpirationType Type
 Expiration Types allowed through the filter Standards only by default More...
 
- Properties inherited from QuantConnect.Securities.ContractSecurityFilterUniverse< FutureFilterUniverse >
DateTime LocalTime [get]
 The local exchange current time More...
 

Detailed Description

Represents futures symbols universe used in filtering.

Definition at line 29 of file FutureFilterUniverse.cs.

Constructor & Destructor Documentation

◆ FutureFilterUniverse()

QuantConnect.Securities.FutureFilterUniverse.FutureFilterUniverse ( IEnumerable< Symbol allSymbols,
DateTime  localTime 
)

Constructs FutureFilterUniverse

Definition at line 34 of file FutureFilterUniverse.cs.

Member Function Documentation

◆ IsStandard()

override bool QuantConnect.Securities.FutureFilterUniverse.IsStandard ( Symbol  symbol)
protectedvirtual

Determine if the given Future contract symbol is standard

Returns
True if contract is standard

Implements QuantConnect.Securities.ContractSecurityFilterUniverse< FutureFilterUniverse >.

Definition at line 43 of file FutureFilterUniverse.cs.

Here is the call graph for this function:

◆ ExpirationCycle()

FutureFilterUniverse QuantConnect.Securities.FutureFilterUniverse.ExpirationCycle ( int[]  months)

Applies filter selecting futures contracts based on expiration cycles. See FutureExpirationCycles for details

Parameters
monthsMonths to select contracts from
Returns
Universe with filter applied

Definition at line 53 of file FutureFilterUniverse.cs.


The documentation for this class was generated from the following file: