Lean
$LEAN_TAG$
|
Defines a single option contract at a specific expiration and strike price More...
Public Member Functions | |
OptionContract (ISecurityPrice security) | |
Initializes a new instance of the OptionContract class More... | |
OptionContract (OptionUniverse contractData, SymbolProperties symbolProperties) | |
Initializes a new option contract from a given OptionUniverse instance More... | |
override string | ToString () |
Returns a string that represents the current object. More... | |
Static Public Member Functions | |
static OptionContract | Create (BaseData baseData, ISecurityPrice security, BaseData underlying) |
Creates a OptionContract More... | |
static OptionContract | Create (DateTime endTime, ISecurityPrice security, BaseData underlying) |
Creates a OptionContract More... | |
static OptionContract | Create (OptionUniverse contractData, SymbolProperties symbolProperties) |
Creates a new option contract from a given OptionUniverse instance, using its data to form a quote bar to source pricing data More... | |
static implicit | operator Symbol (OptionContract contract) |
Implicit conversion into Symbol More... | |
Public Attributes | |
SecurityIdentifier | ID => Symbol.ID |
The security identifier of the option symbol More... | |
Symbol | UnderlyingSymbol => Symbol.Underlying |
Gets the underlying security's symbol More... | |
decimal | Strike => Symbol.ID.StrikePrice |
Gets the strike price More... | |
decimal | ScaledStrike => Strike * _symbolProperties.StrikeMultiplier |
Gets the strike price multiplied by the strike multiplier More... | |
DateTime | Expiry => Symbol.ID.Date |
Gets the expiration date More... | |
OptionRight | Right => Symbol.ID.OptionRight |
Gets the right being purchased (call [right to buy] or put [right to sell]) More... | |
OptionStyle | Style => Symbol.ID.OptionStyle |
Gets the option style More... | |
decimal | TheoreticalPrice => _optionData.TheoreticalPrice |
Gets the theoretical price of this option contract as computed by the IOptionPriceModel More... | |
decimal | ImpliedVolatility => _optionData.ImpliedVolatility |
Gets the implied volatility of the option contract as computed by the IOptionPriceModel More... | |
Greeks | Greeks => _optionData.Greeks |
Gets the greeks for this contract More... | |
decimal | OpenInterest => _optionData.OpenInterest |
Gets the open interest More... | |
decimal | LastPrice => _optionData.LastPrice |
Gets the last price this contract traded at More... | |
long | Volume => _optionData.Volume |
Gets the last volume this contract traded at More... | |
decimal | BidPrice => _optionData.BidPrice |
Gets the current bid price More... | |
long | BidSize => _optionData.BidSize |
Get the current bid size More... | |
decimal | AskPrice => _optionData.AskPrice |
Gets the ask price More... | |
long | AskSize => _optionData.AskSize |
Gets the current ask size More... | |
decimal | UnderlyingLastPrice => _optionData.UnderlyingLastPrice |
Gets the last price the underlying security traded at More... | |
Properties | |
Symbol | Symbol [get, set] |
Gets the option contract's symbol More... | |
DateTime | Time [get, set] |
Gets the local date time this contract's data was last updated More... | |
Properties inherited from QuantConnect.Data.ISymbolProvider | |
Symbol | Symbol [get, set] |
Gets the Symbol More... | |
Properties inherited from QuantConnect.Securities.ISymbol | |
SecurityIdentifier | ID [get] |
Gets the security identifier. More... | |
Defines a single option contract at a specific expiration and strike price
Definition at line 27 of file OptionContract.cs.
QuantConnect.Data.Market.OptionContract.OptionContract | ( | ISecurityPrice | security | ) |
Initializes a new instance of the OptionContract class
security | The option contract security |
Definition at line 142 of file OptionContract.cs.
QuantConnect.Data.Market.OptionContract.OptionContract | ( | OptionUniverse | contractData, |
SymbolProperties | symbolProperties | ||
) |
Initializes a new option contract from a given OptionUniverse instance
contractData | The option universe contract data to use as source for this contract |
symbolProperties | The contract symbol properties |
Definition at line 153 of file OptionContract.cs.
override string QuantConnect.Data.Market.OptionContract.ToString | ( | ) |
Returns a string that represents the current object.
|
static |
Creates a OptionContract
baseData | |
security | Provides price properties for a Security |
underlying | Last underlying security trade data |
|
static |
Creates a OptionContract
endTime | local date time this contract's data was last updated |
security | provides price properties for a Security |
underlying | last underlying security trade data |
Definition at line 194 of file OptionContract.cs.
|
static |
Creates a new option contract from a given OptionUniverse instance, using its data to form a quote bar to source pricing data
contractData | The option universe contract data to use as source for this contract |
symbolProperties | The contract symbol properties |
Definition at line 211 of file OptionContract.cs.
|
static |
Implicit conversion into Symbol
contract | The option contract to be converted |
Definition at line 225 of file OptionContract.cs.
SecurityIdentifier QuantConnect.Data.Market.OptionContract.ID => Symbol.ID |
The security identifier of the option symbol
Definition at line 43 of file OptionContract.cs.
Symbol QuantConnect.Data.Market.OptionContract.UnderlyingSymbol => Symbol.Underlying |
Gets the underlying security's symbol
Definition at line 48 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.Strike => Symbol.ID.StrikePrice |
Gets the strike price
Definition at line 53 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.ScaledStrike => Strike * _symbolProperties.StrikeMultiplier |
Gets the strike price multiplied by the strike multiplier
Definition at line 58 of file OptionContract.cs.
DateTime QuantConnect.Data.Market.OptionContract.Expiry => Symbol.ID.Date |
Gets the expiration date
Definition at line 63 of file OptionContract.cs.
OptionRight QuantConnect.Data.Market.OptionContract.Right => Symbol.ID.OptionRight |
Gets the right being purchased (call [right to buy] or put [right to sell])
Definition at line 68 of file OptionContract.cs.
OptionStyle QuantConnect.Data.Market.OptionContract.Style => Symbol.ID.OptionStyle |
Gets the option style
Definition at line 73 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.TheoreticalPrice => _optionData.TheoreticalPrice |
Gets the theoretical price of this option contract as computed by the IOptionPriceModel
Definition at line 78 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.ImpliedVolatility => _optionData.ImpliedVolatility |
Gets the implied volatility of the option contract as computed by the IOptionPriceModel
Definition at line 83 of file OptionContract.cs.
Greeks QuantConnect.Data.Market.OptionContract.Greeks => _optionData.Greeks |
Gets the greeks for this contract
Definition at line 88 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.OpenInterest => _optionData.OpenInterest |
Gets the open interest
Definition at line 101 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.LastPrice => _optionData.LastPrice |
Gets the last price this contract traded at
Definition at line 106 of file OptionContract.cs.
long QuantConnect.Data.Market.OptionContract.Volume => _optionData.Volume |
Gets the last volume this contract traded at
Definition at line 111 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.BidPrice => _optionData.BidPrice |
Gets the current bid price
Definition at line 116 of file OptionContract.cs.
long QuantConnect.Data.Market.OptionContract.BidSize => _optionData.BidSize |
Get the current bid size
Definition at line 121 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.AskPrice => _optionData.AskPrice |
Gets the ask price
Definition at line 126 of file OptionContract.cs.
long QuantConnect.Data.Market.OptionContract.AskSize => _optionData.AskSize |
Gets the current ask size
Definition at line 131 of file OptionContract.cs.
decimal QuantConnect.Data.Market.OptionContract.UnderlyingLastPrice => _optionData.UnderlyingLastPrice |
Gets the last price the underlying security traded at
Definition at line 136 of file OptionContract.cs.
|
getset |
Gets the option contract's symbol
Definition at line 36 of file OptionContract.cs.
|
getset |
Gets the local date time this contract's data was last updated
Definition at line 94 of file OptionContract.cs.