IVolatilityModel
QuantConnect.Securities.IVolatilityModel
Represents a model that computes the volatility of a security
volatility
volatility: float
Gets the volatility of the security as a percentage
get_history_requirements
get_history_requirements(
security: Security, utc_time: Union[datetime, date]
) -> Sequence[HistoryRequest]
Returns history requirements for the volatility model expressed in the form of history request
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
security
|
Security
|
The security of the request |
required |
utc_time
|
Union[datetime, date]
|
The date/time of the request |
required |
Returns:
| Type | Description |
|---|---|
Sequence[HistoryRequest]
|
History request object list, or empty if no requirements. |
update
warm_up
warm_up(
history_provider: IHistoryProvider,
subscription_manager: SubscriptionManager,
security: Security,
utc_time: Union[datetime, date],
time_zone: Any,
live_mode: bool,
data_normalization_mode: Optional[
DataNormalizationMode
] = None,
) -> None
Warms up the security's volatility model. This can happen either on initialization or after a split or dividend is processed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
history_provider
|
IHistoryProvider
|
The history provider to use to get historical data |
required |
subscription_manager
|
SubscriptionManager
|
The subscription manager to use |
required |
security
|
Security
|
The security which volatility model is being warmed up |
required |
utc_time
|
Union[datetime, date]
|
The current UTC time |
required |
time_zone
|
Any
|
The algorithm time zone |
required |
live_mode
|
bool
|
Whether the algorithm is in live mode |
required |
data_normalization_mode
|
Optional[DataNormalizationMode]
|
The security subscribed data normalization mode |
None
|