Building a Cost-Aware Objective for a One-Period Stat-Arb Portfolio
Statistics & ExperimentsModel answerLast updated
Augment a mean-variance stat-arb objective with realistic trading and holding costs, make units consistent, avoid double counting, calibrate from data, and check convexity.
You run a single-period statistical-arbitrage strategy. Today you hold a portfolio h0 (dollar positions per asset) and you want to move to a target portfolio h. The trade vector is delta = h - h0.
The baseline objective maximizes expected profit minus a risk penalty:
alpha' h - (gamma / 2) h' Sigma h
This ignores the cost of getting to h and of holding it. Your task is to extend the objective so that it reflects real-world frictions.
What to cover
- Propose concrete cost terms for each of the following, and give a functional form for each:
- commissions and other per-unit fees
- bid-ask spread
- slippage
- nonlinear market impact
- turnover
- short-borrow fees
- concentration
- Explain how every term is put in the same units as expected profit.
- Identify which terms overlap, and how you would avoid double counting.
- Describe how each parameter would be calibrated from data.
- State when the final optimization problem stays convex, and what breaks convexity.
Assumptions
- Point-in-time prices, spreads, volumes, volatilities, and borrow-rate estimates are available for every asset.
- All costs must be in the same objective units as expected profit (for example dollars over the forecast horizon).
- Buy and sell costs may differ.
Clarifications you should state or ask about
- What execution horizon, order type, and participation rate do you assume?
- Are the alpha forecasts gross, or already net of some costs?
- Is borrow charged on the full target short position or only on the incremental short?
- Which cost components can actually be separated empirically?
Hints
Hint 1
Split costs into two families: those that depend on the trade `delta` (commission, spread, slippage, impact, turnover) and those that depend on the held position `h` (borrow, concentration).
Hint 2
Write every term in dollars over the alpha horizon. Impact is usually proportional to |trade|^(3/2) or a similar power times volatility and a liquidity scale, and it only stays convex if the exponent is at least 1 and the coefficient is nonnegative.
Hint 3
Think about which terms are really the same effect measured twice, for example spread vs. a fitted linear slippage coefficient, or a turnover penalty vs. impact, and calibrate on the residual rather than the total.
Hint 4
For convexity, check each term: absolute value, positive-part, and power functions with exponent >= 1 are convex; a fixed per-trade fee, a minimum lot size, or a concave impact curve are not.
Model answer
Medium Try it yourself first — then compare your approach, complexity and edge cases.
Setup and framing
Work in dollars. Let h0 be current dollar holdings, h the target, delta = h - h0. Split delta into buys and sells, delta = b - s with b, s >= 0, so costs can be asymmetric. The net objective is:
max_h alpha' h - (gamma/2) h' Sigma h - C_trade(delta) - C_hold(h)
Everything is expressed in dollars over the alpha horizon. If alpha is a return forecast, multiply by position in dollars. If costs are quoted in basis points, multiply by traded notional. If borrow is an annual rate, scale by horizon/252 (or 365).
Trade-dependent costs, C_trade(delta)
Commissions and fees (linear). sum_i c_i^+ b_i + c_i^- s_i. Includes exchange, clearing, and regulatory fees, with sells often carrying extra fees. Convex (linear).
Bid-ask spread. Crossing the spread costs half the quoted spread per dollar: sum_i (S_i / 2) |delta_i|, where S_i is the relative spread. Convex. If you post passively, scale by an expected fill/cross probability.
Slippage. The shortfall between decision price and average fill caused by delay and short-term drift. Model as a linear term sum_i k_i |delta_i|, with k_i proportional to volatility times the square root of delay. Keep it separate from spread only if the data supports it (see overlap below).
Nonlinear market impact. The square-root law is the standard empirical shape:
impact_i = Y * sigma_i * (|delta_i| / ADV_i)^(1/2) per dollar traded, so total cost is Y * sigma_i * |delta_i|^(3/2) / ADV_i^(1/2).
Here sigma_i is daily volatility, ADV_i is average daily dollar volume, and Y is an order-one constant. The cost grows as |delta|^(3/2), which is convex. You can also use a quadratic approximation (1/2) delta' Lambda delta with diagonal Lambda, which makes the problem a QP. Use separate coefficients for buys and sells if the data shows asymmetry. Cross-impact (off-diagonal Lambda) is possible but must stay positive semidefinite.
Turnover penalty. tau * ||delta||_1, or a hard cap ||delta||_1 <= T. This is a regularizer for model uncertainty: alphas are noisy, so trading less than the unconstrained solution is a form of shrinkage. It should be used only for what the physical cost terms do not capture, otherwise you are double penalizing.
Holding-dependent costs, C_hold(h)
Short-borrow fees. sum_i beta_i * (h_i)^- where (x)^- = max(-x, 0) and beta_i is the borrow rate scaled to the horizon. This is convex because it is a positive part with a nonnegative coefficient. Decide whether it applies to the full target short (usual for an ongoing position) or only to incremental shorts; for a one-period model of a book that is held through the horizon, charge on the full target short. Hard-to-borrow names may also need a capacity constraint h_i >= -L_i.
Concentration. Options include a quadratic penalty (lambda_c / 2) sum_i w_i h_i^2, an L-infinity or per-name cap |h_i| <= u_i, a sector or factor exposure limit |F' h| <= f, or a fraction-of-ADV cap |h_i| <= p * ADV_i. All of these are convex. Quadratic penalties are the soft version, caps are the hard version. Per-name liquidity caps are also a safeguard against extrapolating the impact model outside its calibrated range.
Overlap and double counting
- Spread vs. slippage vs. impact. An empirical regression of realized shortfall on trade size has an intercept (spread plus fixed slippage) and a size-dependent part (impact). Fit the impact term on the residual after subtracting half-spread and commission, and do not add a second linear slippage term if the intercept already holds it.
- Turnover vs. impact. If impact is well calibrated, an extra turnover penalty is just a robustness knob. Tune it by out-of-sample net performance, and report it separately.
- Alpha net or gross. If the alpha forecast was trained on returns net of spread, do not subtract spread again.
- Borrow vs. alpha. Short-side alphas may already embed the cost of shorting in realized returns. Confirm which convention the research used.
- Risk vs. concentration. A concentration penalty on top of a well-estimated covariance matrix partly duplicates the risk term. Use it for estimation error and liquidity, not as a second risk measure.
Calibration
- Use point-in-time data only, with no look-ahead in spreads, volume, or volatility.
- Commission and fees: read from the broker and exchange schedules.
- Spread: average quoted or effective spread by name and time of day.
- Impact and slippage: regress implementation shortfall (fill price vs. arrival price, signed) on
sigma * sqrt(participation)and a constant, using your own execution records, ideally with fixed-effects by liquidity bucket. Shrink noisy per-name coefficients toward a bucket mean. - Borrow: use the vendor or prime-broker rate, with a conservative haircut for names whose rate changes quickly.
- Penalty weights (
tau,lambda_c): choose by walk-forward backtest of net PnL, not in-sample fit. - Check stability by comparing predicted and realized costs on a hold-out period and by size decile.
Convexity
The problem is convex when the risk term has Sigma positive semidefinite, and every cost is convex in delta or h:
- linear, absolute value, positive-part, and
|x|^pwithp >= 1are all convex, so the whole objective is a concave maximization, which is a convex problem. - With a quadratic impact the problem is a QP, and with
|x|^(3/2)it is a convex program solvable as a second-order cone problem or with a general convex solver.
What breaks convexity:
- fixed per-trade fees or minimum ticket sizes (binary or integer variables),
- lot-size constraints and cardinality limits on the number of names,
- concave impact (exponent below 1 in total cost, for example total cost proportional to |delta|^(1/2)),
- different buy and sell costs that make the effective cost curve non-convex around zero (for example a rebate on one side larger than the cost on the other),
- cross-impact matrices that are not positive semidefinite,
- borrow tiers where the rate falls at larger short sizes.
Typical fixes are a convex relaxation, a sequence of convex approximations, or a mixed-integer step applied after the continuous solution.
Common mistakes
- mixing units (basis points vs. dollars vs. per-share),
- charging half-spread on both legs of a round trip incorrectly or charging it again inside the slippage term,
- using the end-of-day volume for a forecast made at the open (look-ahead),
- applying borrow to long positions or to incremental rather than total shorts without saying so,
- assuming impact is symmetric and permanent when it is partly temporary and decays within the horizon,
- adding a large turnover penalty to hide a poorly calibrated impact model.