RE:CZ

Capital Persistence War Experiment Design

Capital Protracted War

👤 Quantitative trading researchers, algorithmic trading developers, financial engineering professionals, and traders interested in fund management and risk control strategies.
This article elaborates on a quantitative trading experiment design named 'Capital Persistence War,' with the core concept of using a benchmark account (always trading with 1 unit position) to guide the fund management of a betting account. The betting account employs the Anti-Martingale strategy to dynamically adjust positions, with key elements including time scale t, unrealized/realized profit and loss, risk control line (RiskLine), venture capital (VC), benchmark stop-loss amount (StopLoss), and position size calculation. The document also defines trigger conditions and handling procedures for profit-taking and stop-loss events, emphasizing maximizing venture capital utilization efficiency under risk control conditions and establishing an observation period mechanism. Overall, it aims to build a systematic trading framework to optimize fund management and risk control.
  • ✨ Dynamic fund management design based on benchmark accounts and the Anti-Martingale strategy
  • ✨ Achieving strict risk control through risk control line and venture capital (VC)
  • ✨ Calculating aggressive positions based on benchmark stop-loss amount (StopLoss) to maximize capital efficiency
  • ✨ Defining trigger conditions and state reset rules for profit-taking and stop-loss events
  • ✨ Establishing an observation period mechanism to pause trading when parameters are zero
📅 2026-02-02 · 874 words · ~4 min read
  • Quantitative Trading
  • Fund Management
  • Anti-Martingale
  • Risk Control
  • Experiment Design
  • Position Management

Capital Persistence War Experimental Design

2026-02-02

Reorganize the underlying concepts of the experimental design, as the details of the AI-generated code still need refinement.

Time Scale t

Time scale t is discrete, representing each moment in the market. It can be minutes, hours, days, etc. Typically, it refers to each K-line. Many time series will be discussed next, and their independent variable is t.

Benchmark Account

The benchmark account is an account that does not use any capital management strategy. It always trades with an initial position size of 1 unit. The performance of the benchmark account is used to guide the capital management of the betting account.

  • Cumulative P&L of the Benchmark Account, BasePnL(t), a time series with an initial value of 0. It always trades with an initial position size of 1 unit. The resulting cumulative P&L curve.

Betting Account

The betting account uses an Anti-Martingale capital management strategy, dynamically adjusting the position size based on the performance of the benchmark account.

Important parameters:

  • Target Take-Profit Amount M_T, determined by the betting strategy parameters.

Objects of study:

  • Unrealized P&L UnrealizedPnL(t), a time series representing the unrealized P&L of the benchmark account's current position. Initial value is 0.

  • Realized P&L RealizedPnL(t), a time series representing the realized P&L of the benchmark account. Initial value is 0.

  • Cumulative P&L PnL(t), a time series representing the profit and loss generated by the system. It is always equal to PnL(t) = UnrealizedPnL(t) + RealizedPnL(t). This PnL is the net value curve. It can be linearly scaled to any initial capital size. The performance of the betting model can be observed through PnL(t).

Risk Control

Determining Input Cash Flow

Input Cash Flow C(t), a time series representing the rate of input cash flow (note: not the total amount).

Derived from the historical performance of the benchmark account and dynamically updated.

The recommended calculation method is: calculate the maximum loss / time duration for each trade in the benchmark account and use that value as C(t).

Constructing a Hard Risk Control Line

Risk Control Line RiskLine, initial value is 0.

Naturally iterates according to RiskLine(t+1) = RiskLine(t) - C(t). Upon taking profit, RiskLine is reset to 0.

The risk control line moves downward over time. At any moment, it is guaranteed that UnrealizedPnL(t) >= RiskLine(t).

Venture Capital (VC)

Always equal to VC(t) = UnrealizedPnL(t) - RiskLine(t), representing the capital currently available for betting, which bears the full risk of loss. Venture capital is always non-negative.

Determining Position Size

In principle, under risk control conditions, bet as aggressively as possible to maximize the utilization efficiency of venture capital. Any action that wastes venture capital is meaningless. Each position size is determined with the determination to lose the entire VC(t) if the maximum loss occurs, not wasting any portion of venture capital.

Benchmark Stop-Loss Amount, StopLoss(t)

Represents the maximum floating loss amount set per unit of position, i.e., the stop-loss amount during the holding period. If this stop-loss line is touched during the holding period, it will cause an intraday exit. The benchmark stop-loss amount is derived from the historical performance of the benchmark account and dynamically updated.

The recommended calculation method is: calculate the maximum intraday floating loss for each trade in the benchmark account and use that value as StopLoss(t). Note: calculate the intraday floating loss, not the final P&L. For long positions, use the lowest price; for short positions, use the highest price.

Position Size, a non-negative integer representing the multiple of the betting account's position relative to the benchmark account's position.

if StopLoss(t) > 0 then
    Position(t) = min(1, floor(VC(t) / StopLoss(t)))
else
    Position(t) = 0
end if

Note: If StopLoss(t) = 0.01 and VC(t) = 1, this means we would open a position 100 times the benchmark position. This appears to be a very aggressive position. For example, the minimum trading amount for a BTC contract is 0.0001 BTC, so a 100x position would only be a 0.01 BTC position, which doesn't seem intimidating. However, it is still necessary to observe whether this multiple is too large, making it impractical in actual operation.

Observation Period

When C(t) is 0 or StopLoss(t) is 0, it indicates an observation period. No trading occurs; only C(t) and StopLoss(t) are updated. Position(t) is always 0.

Take-Profit Event

When UnrealizedPnL(t) >= M_T, a take-profit event is triggered, and take-profit processing is performed. Since take-profit is triggered intraday, UnrealizedPnL(t) can only reach M_T and cannot exceed it. When checking for take-profit events, the highest floating profit during the holding period must be used. For long positions, use the highest price; for short positions, use the lowest price.

Record the take-profit event, reset RiskLine(t) = UnrealizedPnL(t) = 0, making VC(t) = 0.

RealizedPnL(t) += M_T
UnrealizedPnL(t) = 0
RiskLine(t) = 0

The observed information C(t) and StopLoss(t) remain unchanged.

Stop-Loss Event

When the maximum floating loss during the holding period >= StopLoss(t), a stop-loss event is triggered, and stop-loss processing is performed.

Record the stop-loss event. UnrealizedPnL(t) can only draw down to RiskLine(t) at most, i.e., VC(t) = 0.

Stop-loss also occurs intraday. After a stop-loss occurs, the current trade is terminated. Even if the price rebounds later, the loss is already locked in. The risk capital will return to zero, but no state actually needs to be reset. Stop-loss occurs, but the system continues running.

The benchmark account and the observed information C(t) and StopLoss(t) remain unchanged.

See Also

Referenced By