How 0xPulse fills your signals
The rules the simulator applies to every signal, the same for everyone, versioned and locked by worked examples computed by hand.
Updated
0xPulse replays your signals against Binance USDⓈ-M futures market data, one minute at a time, and fills them the way
the exchange would. Where the data cannot tell what happened inside a minute, it assumes the outcome that is worse for
you. The rules are versioned (the current set is sim-rules/3) and every result names the version it ran under, so a
result never changes behind your back.
The examples below come from the hand-computed test cases the engine must reproduce to the last digit. They use a round test contract (price step 0.1, quantity step 0.001), a 10,000 USDT account, a 1,000 USDT position, 2x leverage and a 0.05% taker fee, unless they say otherwise.
When a signal fills
A signal’s timestamp is the moment your strategy decided. 0xPulse fills it as a market order at the open of the first 1-minute candle that starts at or after that moment. A signal at 10:00:03 fills at the 10:01 open; a signal at exactly 10:00:00 fills at the 10:00 open.
The simulator never uses a price your strategy could not have seen yet: not the close of the candle that produced the signal, and not a better price later in the minute.
For bots whose logs carry the exact decision time, an advanced setting fills at the first real trade on Binance after the decision plus a latency you choose, instead of the next candle open.
Prices, fees and slippage
- Fill price. Buying pays the reference price plus slippage, rounded up to the contract’s price step; selling gets the reference minus slippage, rounded down. Rounding always goes against you, as on the exchange.
- Fee.
quantity × fill price × taker rate, taken from the wallet at each fill. Market orders are always taker. - Slippage cost is reported on its own, so you can see what it took, but it is already inside the fill price.
A long opened at 40,000 and closed at 40,400 (test case GC-01):
| Value | |
|---|---|
| Quantity | 1,000 / 40,000 = 0.025 BTC |
| Fee to open | 1,000 × 0.05% = 0.50 |
| Fee to close | 0.025 × 40,400 × 0.05% = 0.505 |
| Gross profit | 0.025 × 400 = 10.00 |
| Net profit | 10 − 1.005 = 8.995 |
Size and leverage
You size each position by a fixed notional, a percentage of the wallet, or the share of the wallet you are willing to lose if the stop-loss is hit. Quantity is rounded down to the contract’s quantity step, and orders below the minimum size or above the leverage bracket are rejected with a reason, never resized silently.
Leverage does not change the size of a position. It changes the margin locked and the liquidation price. The same 1,000 USDT long at 5x instead of 2x makes exactly the same profit; only the margin drops from 500 to 200 (GC-04).
Stop-loss and take-profit
Levels are set from the entry price and trigger on the traded price, like Binance’s default. They are checked from the candle the position opens in.
- Both hit in the same candle: a 1-minute candle does not say whether its high or its low came first, so the stop-loss is taken first. A long from 40,000 with a 1% stop and a 2% target, in a candle from 39,500 to 40,900, closes at the 39,600 stop for a net loss of 10.995 (GC-11).
- Gap through the stop: if the candle opens beyond the stop, the fill is at the open, not at the stop. The same long, with a next candle opening at 39,400, closes at 39,400 for a net loss of 15.9925 (GC-10).
- Gap through the target: the fill is at the open, which is the better price, as a take-profit market order would fill on the exchange.
Signals while a position is open
One position per symbol, in one-way mode, as Binance sets by default.
| Position | Open long | Open short | Close |
|---|---|---|---|
| Flat | Opens a long | Opens a short | Ignored, noted |
| Long | Ignored, noted | Reverses | Closes |
| Short | Reverses | Ignored, noted | Closes |
A reversal closes the position and opens the opposite one at the same candle open: two fills, two fees. Every signal ends with exactly one outcome you can read in the Signals table, with the reason when it did not fill.
Funding
Funding comes from Binance’s historical rates. A position pays or receives it when it was opened before the
funding minute and is still open then: quantity × mark price × rate. A long of 0.025 BTC at a mark of 40,100 and a
rate of 0.01% pays 0.10025; the same long opened at the funding minute itself pays nothing (GC-19).
Liquidation
Liquidation follows Binance’s tiered maintenance margin and triggers on the mark price, in cross or isolated margin. A liquidated position closes at the liquidation price, or at the mark open if the price gapped through it, and pays the liquidation fee out of what is left of its margin. The wallet never goes negative.
The same 10,000 USDT long at 20x, through a dip whose mark low is 38,100 (GC-22):
| Margin | Liquidation price | What happens | Net |
|---|---|---|---|
| Isolated | 38,152.6, 4.62% below entry | Liquidated in the dip | −505 |
| Cross | 20.1: the whole wallet backs the position | Closed by the next signal at 38,500 | −384.8125 |
Isolated loses exactly its margin and the fee to open, and no more. Cross survives this dip, but it puts the whole wallet at risk to do so.
Missing data and exchange maintenance
If the candle a signal needs had no trading (Binance maintenance), the signal waits for the first tradable candle, for up to 240 minutes, and is marked as filled late. Longer than that, it is skipped with a reason. While a position is open over missing candles, the gap is reported; prices are never interpolated.
Market data
- Binance USDⓈ-M perpetual futures: BTCUSDT and ETHUSDT today.
- 1-minute candles for fills, stops and targets; 1-minute mark prices for liquidation, funding and the equity curve; historical funding rates.
- Every run records the dataset version it used. When the data is corrected, older runs keep explaining their numbers, and a new run uses the new version.
Exact and repeatable
Money, prices and quantities are computed in decimal arithmetic, never floating point, and rounded only where the exchange rounds. The same signals, settings, contract and data under the same rules version give the same result to the last digit, and every trade can be traced from the signal line to the fill, the fee and the profit or loss.
Known limits
Every result lists its assumptions. The ones that matter most:
- Slippage is a fixed share of the price. Large orders and fast markets cost more on the exchange.
- 1-minute candles. When both directions are possible inside a minute, the worse one is assumed.
- Contract rules are today’s. Minimum sizes and leverage brackets have changed since 2019, so small orders in older periods can be accepted or rejected differently than they were then.
- One fee rate per run. VIP tiers and BNB discounts are not modelled; set the rate you pay.
- Whole-position liquidation. No partial liquidation or auto-deleveraging, which only matters for very large positions.
- Isolated margin is fixed. Adding margin to save a position is not simulated.
Results are simulations of your own signals on historical data. They are not investment advice and do not promise future returns.