Lean  $LEAN_TAG$
QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T > Class Template Reference

ConstituentsUniverse allows to perform universe selection based on an already preselected set of Symbol. More...

Inheritance diagram for QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >:
[legend]

Public Member Functions

 ConstituentsUniverse (Symbol symbol, UniverseSettings universeSettings, Func< IEnumerable< T >, IEnumerable< Symbol >> constituentsFilter=null)
 Creates a new instance of the ConstituentsUniverse More...
 
 ConstituentsUniverse (Symbol symbol, UniverseSettings universeSettings, PyObject constituentsFilter=null)
 Creates a new instance of the ConstituentsUniverse More...
 
 ConstituentsUniverse (SubscriptionDataConfig subscriptionDataConfig, UniverseSettings universeSettings, Func< IEnumerable< T >, IEnumerable< Symbol >> constituentsFilter=null)
 Creates a new instance of the ConstituentsUniverse More...
 
 ConstituentsUniverse (SubscriptionDataConfig subscriptionDataConfig, UniverseSettings universeSettings, PyObject constituentsFilter=null)
 Constituent universe for a Python function More...
 
 ConstituentsUniverse (Symbol symbol, UniverseSettings universeSettings, Func< IEnumerable< ConstituentsUniverseData >, IEnumerable< Symbol >> filterFunc)
 Creates a new instance of the ConstituentsUniverse More...
 
 ConstituentsUniverse (Symbol symbol, UniverseSettings universeSettings)
 Creates a new instance of the ConstituentsUniverse More...
 
 ConstituentsUniverse (Symbol symbol, UniverseSettings universeSettings, PyObject filterFunc)
 Creates a new instance of the ConstituentsUniverse More...
 
- Public Member Functions inherited from QuantConnect.Data.UniverseSelection.FuncUniverse< T >
 FuncUniverse (SubscriptionDataConfig configuration, UniverseSettings universeSettings, Func< IEnumerable< T >, IEnumerable< Symbol >> universeSelector)
 Initializes a new instance of the FuncUniverse<T> class More...
 
 FuncUniverse (SubscriptionDataConfig configuration, UniverseSettings universeSettings, PyObject universeSelector)
 Initializes a new instance of the FuncUniverse<T> class for a filter function loaded from Python More...
 
override IEnumerable< SymbolSelectSymbols (DateTime utcTime, BaseDataCollection data)
 Performs an initial, coarse filter More...
 
 FuncUniverse (SubscriptionDataConfig configuration, UniverseSettings universeSettings, Func< IEnumerable< BaseData >, IEnumerable< Symbol >> universeSelector)
 Initializes a new instance of the FuncUniverse class More...
 
 FuncUniverse (SubscriptionDataConfig configuration, UniverseSettings universeSettings, PyObject universeSelector)
 Initializes a new instance of the FuncUniverse class More...
 
- Public Member Functions inherited from QuantConnect.Data.UniverseSelection.Universe
virtual bool CanRemoveMember (DateTime utcTime, Security security)
 Determines whether or not the specified security can be removed from this universe. This is useful to prevent securities from being taken out of a universe before the algorithm has had enough time to make decisions on the security More...
 
IEnumerable< SymbolPerformSelection (DateTime utcTime, BaseDataCollection data)
 Performs universe selection using the data specified More...
 
virtual Security CreateSecurity (Symbol symbol, IAlgorithm algorithm, MarketHoursDatabase marketHoursDatabase, SymbolPropertiesDatabase symbolPropertiesDatabase)
 Creates and configures a security for the specified symbol More...
 
virtual IEnumerable< SubscriptionRequestGetSubscriptionRequests (Security security, DateTime currentTimeUtc, DateTime maximumEndTimeUtc)
 Gets the subscription requests to be added for the specified security More...
 
virtual IEnumerable< SubscriptionRequestGetSubscriptionRequests (Security security, DateTime currentTimeUtc, DateTime maximumEndTimeUtc, ISubscriptionDataConfigService subscriptionService)
 Gets the subscription requests to be added for the specified security More...
 
bool ContainsMember (Symbol symbol)
 Determines whether or not the specified symbol is currently a member of this universe More...
 
virtual void Dispose ()
 Marks this universe as disposed and ready to remove all child subscriptions More...
 

Additional Inherited Members

- Public Attributes inherited from QuantConnect.Data.UniverseSelection.Universe
SecurityType SecurityType => Configuration.SecurityType
 Gets the security type of this universe More...
 
string Market => Configuration.Market
 Gets the market of this universe More...
 
Symbol Symbol => Configuration.Symbol
 Gets the symbol of this universe More...
 
Type DataType => Configuration.Type
 Gets the data type of this universe More...
 
- Static Public Attributes inherited from QuantConnect.Data.UniverseSelection.Universe
static readonly UnchangedUniverse Unchanged = UnchangedUniverse.Instance
 Gets a value indicating that no change to the universe should be made More...
 
- Protected Member Functions inherited from QuantConnect.Data.UniverseSelection.Universe
 Universe (SubscriptionDataConfig config)
 Initializes a new instance of the Universe class More...
 
void OnSelectionChanged (HashSet< Symbol > selection=null)
 Event invocator for the SelectionChanged event More...
 
- Properties inherited from QuantConnect.Data.UniverseSelection.Universe
virtual ConcurrentDictionary< Symbol, MemberSecurities [get]
 Gets the internal security collection used to define membership in this universe More...
 
HashSet< SymbolSelected [get, set]
 The currently selected symbol set More...
 
virtual bool Asynchronous [get, set]
 True if this universe filter can run async in the data stack More...
 
virtual bool DisposeRequested [get, protected set]
 Flag indicating if disposal of this universe has been requested More...
 
virtual UniverseSettings UniverseSettings [get, set]
 Gets the settings used for subscriptions added for this universe More...
 
virtual SubscriptionDataConfig Configuration [get]
 Gets the configuration used to get universe data More...
 
Dictionary< Symbol, SecurityMembers [get]
 Gets the current listing of members in this universe. Modifications to this dictionary do not change universe membership. More...
 
- Events inherited from QuantConnect.Data.UniverseSelection.Universe
EventHandler SelectionChanged
 Event fired when the universe selection has changed More...
 

Detailed Description

ConstituentsUniverse allows to perform universe selection based on an already preselected set of Symbol.

Using this class allows a performance improvement, since there is no runtime logic computation required for selecting the Symbol

Type Constraints
T :BaseData 

Definition at line 29 of file ConstituentsUniverse.cs.

Constructor & Destructor Documentation

◆ ConstituentsUniverse() [1/7]

QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >.ConstituentsUniverse ( Symbol  symbol,
UniverseSettings  universeSettings,
Func< IEnumerable< T >, IEnumerable< Symbol >>  constituentsFilter = null 
)

Creates a new instance of the ConstituentsUniverse

Parameters
symbolThe universe symbol
universeSettingsThe universe settings to use
constituentsFilterUser-provided function to filter constituents universe with

Definition at line 38 of file ConstituentsUniverse.cs.

◆ ConstituentsUniverse() [2/7]

QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >.ConstituentsUniverse ( Symbol  symbol,
UniverseSettings  universeSettings,
PyObject  constituentsFilter = null 
)

Creates a new instance of the ConstituentsUniverse

Parameters
symbolThe universe symbol
universeSettingsThe universe settings to use
constituentsFilterUser-provided function to filter constituents universe with

Definition at line 62 of file ConstituentsUniverse.cs.

◆ ConstituentsUniverse() [3/7]

QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >.ConstituentsUniverse ( SubscriptionDataConfig  subscriptionDataConfig,
UniverseSettings  universeSettings,
Func< IEnumerable< T >, IEnumerable< Symbol >>  constituentsFilter = null 
)

Creates a new instance of the ConstituentsUniverse

Parameters
subscriptionDataConfigThe universe configuration to use
universeSettingsThe universe settings to use
constituentsFilterUser-provided function to filter constituents universe with

Definition at line 76 of file ConstituentsUniverse.cs.

◆ ConstituentsUniverse() [4/7]

QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >.ConstituentsUniverse ( SubscriptionDataConfig  subscriptionDataConfig,
UniverseSettings  universeSettings,
PyObject  constituentsFilter = null 
)

Constituent universe for a Python function

Parameters
subscriptionDataConfigThe universe configuration to use
universeSettingsThe universe settings to use
constituentsFilterUser-provided function to filter constituents universe with

Definition at line 108 of file ConstituentsUniverse.cs.

◆ ConstituentsUniverse() [5/7]

QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >.ConstituentsUniverse ( Symbol  symbol,
UniverseSettings  universeSettings,
Func< IEnumerable< ConstituentsUniverseData >, IEnumerable< Symbol >>  filterFunc 
)

Creates a new instance of the ConstituentsUniverse

Parameters
symbolThe universe symbol
universeSettingsThe universe settings to use
filterFuncThe constituents filter function

Definition at line 131 of file ConstituentsUniverse.cs.

◆ ConstituentsUniverse() [6/7]

Creates a new instance of the ConstituentsUniverse

Parameters
symbolThe universe symbol
universeSettingsThe universe settings to use

Definition at line 141 of file ConstituentsUniverse.cs.

◆ ConstituentsUniverse() [7/7]

QuantConnect.Data.UniverseSelection.ConstituentsUniverse< T >.ConstituentsUniverse ( Symbol  symbol,
UniverseSettings  universeSettings,
PyObject  filterFunc 
)

Creates a new instance of the ConstituentsUniverse

Parameters
symbolThe universe symbol
universeSettingsThe universe settings to use
filterFuncThe constituents filter function

Definition at line 152 of file ConstituentsUniverse.cs.


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