Maya,
You’ve built a US equity strategy that shorts sharp opening gaps and holds for up to three sessions. Your simulator charges commissions, crosses the spread and limits participation. Before you spend another afternoon tuning the gap threshold, you need to answer a more basic question: could your account have borrowed those shares?
Your short-selling backtest needs a borrow model whenever securities lending constrains entry or changes the economics of holding. That model needs historical availability, accessible quantity, borrowing charges and a response to recalls. A flat annual fee covers only one piece.
In your case, the omission could change which trades exist. The small names with spectacular gaps may also be the names where borrow is scarce or expensive. You can’t assume that removing unavailable trades leaves a smaller version of the same strategy.
Your first order belongs before the sell order
Picture your next simulated signal: sell 1,000 shares at $10. Your price data says the stock traded plenty of volume. That tells you something about execution capacity. It tells you very little about the inventory your broker can access for your account.
For an ordinary US equity short, your broker generally needs to satisfy the applicable locate requirement before executing the sale. You should keep the distinctions straight in your simulator: a locate provides a basis for believing shares can be borrowed; it isn’t an unconditional reservation of shares through your entire holding period.
| Your historical broker response | Your simulated action |
|---|---|
| 1,000 shares accessible at an acceptable quoted rate | Allow the requested quantity to proceed to execution checks |
| Only 300 shares accessible | Cap the order at 300, if your strategy accepts partial allocations |
| No accessible shares | Reject the entry and record a borrow rejection |
| No historical observation | Mark eligibility unknown and include it in sensitivity analysis |
You need a policy for that 300-share case before seeing its return. Otherwise, you’ll find yourself accepting partial allocations on winners and calling the losers too small to bother with.
And keep your terminology boring. You can call a database column locate_status and understand it six months later. Call it shortable_magic and you’ve bought yourself a tiny maintenance problem. Every research notebook seems to acquire one.
Your three sessions can contain a weekend
Suppose you enter a $10,000 short on Friday and cover on Monday. For this example, assume your broker charges three calendar days of borrow, uses a 365-day denominator and keeps the chargeable balance at $10,000. Those are explicit modeling assumptions; you’ll need your broker’s actual accrual and valuation conventions for a faithful implementation.
| Annualized borrow rate | Daily charge | Three-day charge | Share of entry notional |
|---|---|---|---|
| 30% | $8.22 | $24.66 | 0.247% |
| 100% | $27.40 | $82.19 | 0.822% |
| 360% | $98.63 | $295.89 | 2.959% |
Your calculation is chargeable balance × annualized rate × days ÷ 365. Your real ledger may require a different day basis, daily repricing, collateral conventions or separate locate charges. You should also account for any applicable credit on short-sale proceeds separately.
If the stock falls 2%, your gross price gain is $200. Under the 360% example, you’ve already spent more than that on borrow, before execution costs. You don’t need a subtle statistical argument to reject that trade under those assumptions.
But an entry-time rate filter doesn’t lock in the holding cost. Your borrow rate can change while the position is open. Accrue using each day’s applicable terms; reserve the entry quote for decisions you could actually make at entry.
Your data needs the broker’s perspective
You want timestamped records of the symbol, broker or lending source, availability status, indicated quantity and rate. Preserve the time you received the observation. A nightly file delivered after your morning entry cannot justify that morning’s decision.
You also need to understand what the quantity means. An indicative inventory feed may show inventory shared across customers. It doesn’t necessarily promise your account that allocation. If you have actual locate requests and responses, preserve those alongside the feed.
If you lack historical borrow data, you can still study the signal. Label the result as conditional on borrow, and show how eligibility and rate assumptions change it. You cannot establish historical short feasibility from today’s easy-to-borrow list.
Your useful stress test is selective. Remove or cap trades in the names most exposed to borrow constraints, and vary their rates. Randomly deleting 10% of entries can miss the problem entirely: your best-looking price moves may be concentrated in precisely the difficult names.
Your exit rule doesn’t control every exit
You’ve specified a three-session maximum hold. Your lender and broker haven’t signed that strategy document.
A recall may lead to replacement borrow, or it may lead to a forced close under your broker’s process. You shouldn’t translate every recall into an immediate market buy. You should represent the possible outcomes and, where records exist, replay the actual notifications and deadlines.
Without those records, report a separate stress scenario with an explicit replacement-borrow failure assumption and forced-cover timing. Include the cover’s execution costs. Keep that scenario distinguishable from a reconstruction supported by historical evidence.
For your next run, give every candidate a traceable path: requested shares, borrow decision, allocated shares, executed shares, daily borrowing charges and exit reason. Keep rejected candidates in the output so you can see whether borrow removes the apparent source of the strategy’s edge.
Then reopen your ten largest simulated winners. Beside each one, put the evidence that you could access the shares and keep the position open. Wherever that space is blank, you have your next research task.
← All posts


