Lean
$LEAN_TAG$
|
Market on close order type - submits a market order on exchange close More...
Public Member Functions | |
MarketOnCloseOrder () | |
Intiializes a new instance of the MarketOnCloseOrder class. More... | |
MarketOnCloseOrder (Symbol symbol, decimal quantity, DateTime time, string tag="", IOrderProperties properties=null) | |
Intiializes a new instance of the MarketOnCloseOrder class. More... | |
override Order | Clone () |
Creates a deep-copy clone of this order More... | |
Public Member Functions inherited from QuantConnect.Orders.Order | |
virtual IEnumerable< IPosition > | CreatePositions (SecurityManager securities) |
Creates an enumerable containing each position resulting from executing this order. More... | |
decimal | GetValue (Security security) |
Gets the value of this order at the given market price in units of the account currency NOTE: Some order types derive value from other parameters, such as limit prices More... | |
virtual string | GetDefaultTag () |
Gets the default tag for this order More... | |
virtual void | ApplyUpdateOrderRequest (UpdateOrderRequest request) |
Modifies the state of this order to match the update request More... | |
override string | ToString () |
Returns a string that represents the current object. More... | |
Static Public Attributes | |
static readonly TimeSpan | DefaultSubmissionTimeBuffer = TimeSpan.FromMinutes(15.5) |
Gets the default interval before market close that an MOC order may be submitted. For example, US equity exchanges typically require MOC orders to be placed no later than 15 minutes before market close, which yields a nominal time of 3:45PM. This buffer value takes into account the 15 minutes and adds an additional 30 seconds to account for other potential delays, such as LEAN order processing and placement of the order to the exchange. More... | |
static TimeSpan | SubmissionTimeBuffer = DefaultSubmissionTimeBuffer |
The interval before market close that an MOC order may be submitted. More... | |
Protected Member Functions | |
override decimal | GetValueImpl (Security security) |
Gets the order value in units of the security's quote currency More... | |
Protected Member Functions inherited from QuantConnect.Orders.Order | |
Order () | |
Added a default constructor for JSON Deserialization: More... | |
Order (Symbol symbol, decimal quantity, DateTime time, GroupOrderManager groupOrderManager, string tag="", IOrderProperties properties=null) | |
New order constructor More... | |
Order (Symbol symbol, decimal quantity, DateTime time, string tag="", IOrderProperties properties=null) | |
New order constructor More... | |
void | CopyTo (Order order) |
Copies base Order properties to the specified order More... | |
Properties | |
override OrderType | Type [get] |
MarketOnClose Order Type More... | |
Properties inherited from QuantConnect.Orders.Order | |
int | Id [get, set] |
Order ID. More... | |
int | ContingentId [get, set] |
Order id to process before processing this order. More... | |
List< string > | BrokerId [get, set] |
Brokerage Id for this order for when the brokerage splits orders into multiple pieces More... | |
Symbol | Symbol [get, set] |
Symbol of the Asset More... | |
decimal | Price [get, set] |
Price of the Order. More... | |
string | PriceCurrency [get, set] |
Currency for the order price More... | |
DateTime | Time [get, set] |
Gets the utc time the order was created. More... | |
DateTime? | LastFillTime [get, set] |
Gets the utc time the last fill was received, or null if no fills have been received More... | |
DateTime? | LastUpdateTime [get, set] |
Gets the utc time this order was last updated, or null if the order has not been updated. More... | |
DateTime? | CanceledTime [get, set] |
Gets the utc time this order was canceled, or null if the order was not canceled. More... | |
virtual decimal | Quantity [get, set] |
Number of shares to execute. More... | |
abstract OrderType | Type [get] |
Order Type More... | |
OrderStatus | Status [get, set] |
Status of the Order More... | |
string | Tag [get, set] |
Tag the order with some custom data More... | |
IOrderProperties | Properties [get] |
Additional properties of the order More... | |
OrderDirection | Direction [get] |
Order Direction Property based off Quantity. More... | |
OrderSubmissionData | OrderSubmissionData [get, set] |
Gets the price data at the time the order was submitted More... | |
bool | IsMarketable [get] |
Returns true if the order is a marketable order. More... | |
GroupOrderManager | GroupOrderManager [get, set] |
Manager for the orders in the group if this is a combo order More... | |
DataNormalizationMode | PriceAdjustmentMode [get, set] |
The adjustment mode used on the order fill price More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from QuantConnect.Orders.Order | |
static Order | CreateOrder (SubmitOrderRequest request) |
Creates an Order to match the specified request More... | |
Public Attributes inherited from QuantConnect.Orders.Order | |
DateTime | CreatedTime => Time |
Gets the utc time this order was created. Alias for Time More... | |
TimeInForce | TimeInForce => Properties.TimeInForce |
Order Time In Force More... | |
SecurityType | SecurityType => Symbol.ID.SecurityType |
The symbol's security type More... | |
decimal | AbsoluteQuantity => Math.Abs(Quantity) |
Get the absolute quantity for this order More... | |
decimal | Value => Quantity * Price |
Deprecated More... | |
Market on close order type - submits a market order on exchange close
Definition at line 25 of file MarketOnCloseOrder.cs.
QuantConnect.Orders.MarketOnCloseOrder.MarketOnCloseOrder | ( | ) |
Intiializes a new instance of the MarketOnCloseOrder class.
Definition at line 55 of file MarketOnCloseOrder.cs.
QuantConnect.Orders.MarketOnCloseOrder.MarketOnCloseOrder | ( | Symbol | symbol, |
decimal | quantity, | ||
DateTime | time, | ||
string | tag = "" , |
||
IOrderProperties | properties = null |
||
) |
Intiializes a new instance of the MarketOnCloseOrder class.
symbol | The security's symbol being ordered |
quantity | The number of units to order |
time | The current time |
tag | A user defined tag for the order |
properties | The order properties for this order |
Definition at line 67 of file MarketOnCloseOrder.cs.
|
protectedvirtual |
Gets the order value in units of the security's quote currency
security | The security matching this order's symbol |
Implements QuantConnect.Orders.Order.
Definition at line 76 of file MarketOnCloseOrder.cs.
|
virtual |
Creates a deep-copy clone of this order
Implements QuantConnect.Orders.Order.
Definition at line 85 of file MarketOnCloseOrder.cs.
|
static |
Gets the default interval before market close that an MOC order may be submitted. For example, US equity exchanges typically require MOC orders to be placed no later than 15 minutes before market close, which yields a nominal time of 3:45PM. This buffer value takes into account the 15 minutes and adds an additional 30 seconds to account for other potential delays, such as LEAN order processing and placement of the order to the exchange.
Definition at line 35 of file MarketOnCloseOrder.cs.
|
static |
The interval before market close that an MOC order may be submitted.
Configurable so advanced users may modify this for special cases; Related issue: Github #5481
Definition at line 42 of file MarketOnCloseOrder.cs.
|
get |
MarketOnClose Order Type
Definition at line 48 of file MarketOnCloseOrder.cs.