Quantity calculation method
The Quantity calculation method field controls how entry quantity is calculated. You can set it in your strategy. When Allow signal override next to the quantity settings (or the global Allow signal overrides) is enabled, you can override it in a webhook by sending quantityType and quantity. Allowed quantityType values:
fixed_quantitydollar_amountrisk_dollar_amountrisk_percentpercent_of_equitypercent_of_position
Fixed quantity
Same share (or contract) count for every entry.
- Calculation: quantity = value you provide
- Example:
100→ 100 shares
{
"ticker": "AAPL",
"action": "buy",
"quantityType": "fixed_quantity",
"quantity": 100
}
Dollar amount
Position size from a target notional dollar amount.
- Calculation: quantity = dollar amount ÷ entry price
- Example: $1000 at $100 → 10 shares
{
"ticker": "AAPL",
"action": "buy",
"quantityType": "dollar_amount",
"quantity": 1000
}
Risk dollar amount
Position sized so max loss equals a fixed dollar amount.
- Calculation: quantity = risk $ ÷ |entry − stop|
- Example: $100 risk, entry $100, stop $90 → $10/share → 10 shares
Requires a stop price from the signal (stopLoss.stopPrice) or from the subscription's stop loss configuration.
{
"ticker": "AAPL",
"action": "buy",
"quantityType": "risk_dollar_amount",
"quantity": 100,
"stopLoss": {
"stopPrice": 90
}
}
Risk percent
Position sized so max loss is a percentage of account equity.
- Calculation: risk $ = portfolio × (risk% ÷ 100); quantity = risk $ ÷ |entry − stop|
- Example: 0.25% on $10,000 → $25 risk; entry $100, stop $90 → $10/share → 2.5 shares (rounded)
- Portfolio: Portfolio value is reduced by positive unrealized P&L before sizing.
Requires a stop price from the signal (stopLoss.stopPrice) or from the subscription's stop loss configuration.
{
"ticker": "AAPL",
"action": "buy",
"quantityType": "risk_percent",
"quantity": 0.25,
"stopLoss": {
"stopPrice": 90
}
}
Percent of equity
Position size as a percentage of account equity.
- Calculation: notional = portfolio × (percent ÷ 100); quantity = notional ÷ entry price
- Example: 10% of $10,000 at $100 → $1,000 notional → 10 shares
- Portfolio: Portfolio value is reduced by positive unrealized P&L before sizing.
{
"ticker": "AAPL",
"action": "buy",
"quantityType": "percent_of_equity",
"quantity": 10
}
Percent of position
Exit a percentage of the current position.
- Calculation: quantity = position size × (percent ÷ 100)
- Example: sell 50% of 100 shares → 50 shares (exit quantity)
{
"ticker": "AAPL",
"action": "sell",
"quantityType": "percent_of_position",
"quantity": 50
}
Ready to put Quantity calculation method to work?
Free 7-day trial
Set-up in 3 minutes
Paper account for testing
By continuing, you agree to the TradersPost Terms of Service and Privacy Policy. This site is protected by reCAPTCHA.