QuantConnect Lean Algorithmic Trading Engine
The security to generate a margin call order for
The net liquidation value for the entire account
The total margin used by the account in units of base currency
The percentage of the holding's absolute cost that must be held in free cash in order to avoid a margin call
GenerateMarginCallOrder Method (DefaultMarginCallModel)
Generates a new order for the specified security taking into account the total margin used by the account. Returns null when no margin call is to be issued.
Syntax

Parameters

security
The security to generate a margin call order for
netLiquidationValue
The net liquidation value for the entire account
totalMargin
The total margin used by the account in units of base currency
maintenanceMarginRequirement
The percentage of the holding's absolute cost that must be held in free cash in order to avoid a margin call

Return Value

An order object representing a liquidation order to be executed to bring the account within margin requirements
Requirements

Target Platforms: Microsoft .NET 4.5 or Mono 3.10 or above.

See Also