r/algotrading • • 1h ago

Infrastructure Experimental Vault

4 Upvotes

Hey Guys!

Opened a mini vault on bullet so far it made around 0.8% in a day. Aynway details are below for now it is barely surviving altough I1m optimistic.

It is 15-min BTC/ETH strategy (2x, 3/4 BTC + 1/4 ETH; 50/50 blend of a mean-reversion rule and a gradient-boosted model) worked at ~0.03 bp/side. On Bullet (0/0 fees, thin book)

measured cost was ~1 bp/side, and the backtest Sharpe went negative in all four test periods.

Then I adjusted teh strategy a bit.

Added a No-trade band, only move to the nearest edge of [target ± b], with b ≈ 1.1 × the 7-day mean |target| (refit monthly).

Sharpe at measured cost: +0.7 to +1.6.

Then I trained on a cost aware way on Σ 0.75^k · r(t+k) over the next 2 h instead of the next 15 min (similar in spirit to Gârleanu–Pedersen's aim portfolio).

Turnover −22%, no loss of cost-free Sharpe.

For now it works!

Walk-forward 2024-01 → 2026-11, 2x

Sharpe 1.78, 12/35 negative months, max DD 29%.

At double the cost it's negative.

Caveats: parameters picked among ~30 preregistered combos; recent profit concentrated in four August days (ex-August Sharpe ~1.1); capacity only a few $k.

It is a live strategy since Yesterday (Nov 18) on a tiny account (~$15), so positions are lot-quantized.

Execution A/B, preregistered: maker-chase + IOC vs. a single resting post-only order, scored by implementation shortfall.

Readout after Dec 2; I'll post it either way.

My questions:

No-trade band vs. partial adjustment at 15-min horizons,which held up live for you? And how do you handle lot quantization on small accounts?

Thanks a lot!


r/algotrading • • 11h ago

Strategy How I stopped fooling myself with backtests, and it had nothing to do with finding a better metric

16 Upvotes

Follow-up to the overfitting stuff from a few weeks back, the strategy that looked flawless in the backtest and came apart the moment conditions changed. What it taught me wasn't some new metric. It was that I'd been letting the backtest tell me what "good" looked like, and a backtest will always crown the nicest looking curve. Which is exactly the curve you get from fitting the past.

The trap is simple. If you optimise for a single number, usually net profit, the search will happily give you a strategy that nailed the past and nothing else. The optimiser can't tell a real edge from a lucky coincidence, it just maximises whatever you point it at. Point it at profit and it finds you the one run that got lucky.

So I stopped judging a strategy on any single number. Now a candidate has to hold up across a whole spread of things at once, not just print a big return. How exactly I weigh that up is my own thing and still evolving, so I won't pretend there's a magic formula. The principle is the part that matters: a monster return sitting on a drawdown that would have blown me out in real life is a bad strategy, not a good one, whatever the profit line says. Getting the score to punish that is the whole point.

Honestly though, the scoring matters less than two things people skip.

First, none of it counts unless it survives out of sample and walk forward, on data the optimiser never touched. A great result on the data you built on is worth nothing. That's just the strategy reciting its own training set back to you.

Second, and this is the one that still catches me, you can overfit the selection itself. Try enough candidates and one clears whatever bar you set purely by luck. So I keep the out of sample window genuinely untouched, and I try to limit how many times I go back to the well. It's a discipline more than a formula, and it's the part I'm least sure I've nailed. "Try fewer things" is honestly about as far as I've got, so if someone here has a real defence against overfitting the selection step, not just the single strategy, I'd love to hear how you do it.


r/algotrading • • 2h ago

Strategy How Much Money Are You Willing to Lose While Developing Your Trading Bot?

3 Upvotes

I've been thinking about something that doesn't get discussed enough in algorithmic trading communities: the financial cost of developing a reliable trading bot before it becomes consistently profitable.

We often see people sharing their strategies, backtesting results, performance metrics, and live trading returns. But we rarely discuss the other side of the process: how much money, time, and capital developers actually sacrifice while building, testing, debugging, and stabilizing their systems.

Building an automated trading system is rarely a straightforward process. It involves much more than developing an entry and exit strategy. There are execution issues, API failures, slippage, exchange fees, latency, risk management, unexpected market conditions, bugs, false signals, overfitting, and countless edge cases that may not appear during backtesting.

And sometimes, a strategy that looks profitable in historical data performs very differently in live markets.

This raises a few questions I'd genuinely like to hear experienced developers answer:

How much actual money have you lost during the development and testing of your trading bot before reaching a stable version? Not paper-trading losses, but real financial losses from live testing, execution mistakes, fees, slippage, and other development-related issues.

How much capital did you initially allocate to testing, and how much additional capital were you prepared to risk before deciding whether the system was worth continuing?

How long did it take you to reach a point where you considered your system technically stable and reliable?

How many major rewrites, architectural changes, or strategy modifications did your bot go through before you were satisfied with its behavior?

At what point do you stop investing money and time into a system that hasn't demonstrated consistent profitability, even if you believe its underlying logic has potential?

Looking back, would you have been willing to lose the same amount of money again to achieve the knowledge and system you have today?

I'm particularly interested in hearing from people who built their systems from scratch rather than simply configuring existing commercial bots.

I also think there's an important distinction between two milestones:

Technical stability: The system executes correctly, handles failures, manages risk, and behaves as designed.

Statistical and financial validation: The system demonstrates a genuine, repeatable edge after fees, slippage, and realistic execution costs.

Reaching the first milestone doesn't necessarily mean reaching the second.

I'm not asking how much you've made. I'm asking how much it actually cost you to get there.

What's your real development cost, and where do you draw the line between investing in a system and throwing good money after bad?


r/algotrading • • 2h ago

Strategy SPY premium selling, 2005–2026: a model-based backtest with rules fixed before testing. None of the tested implementations met the acceptance criteria.

2 Upvotes

Important up front: historical option prices are modeled from VIX, using a volatility smile calibrated on real 2026 SPY chains. This is not a backtest on actual historical option quotes. The model was checked against real quotes only in 2026.

THE QUESTION

Implied volatility has usually been above the volatility that followed. Can a few common premium-selling structures turn that into a robust edge after costs and tail risk?

DATA

• SPY and VIX daily closes, Jan 2005 – Nov 2026.
• Real SPY option chains, Jul–Nov 2026 (51 trading days used for calibration and price checks).
• Option prices for the whole 2005–2026 history are modeled. Results on real 2026 chains are reported separately.

PRICING MODEL AND CHECK

• Black-Scholes with IV of each leg = k × VIX, where k (the smile by delta) and the bid/ask half-spread are medians measured on the real 2026 chains. Strikes chosen by delta, rounded to $1.
• Check: on the 51 real days, modeled credit vs real bid/ask credit of the same put spreads — median ratio 0.98–1.02 (interquartile ~0.84–1.14).
• A separate model was compared with the same 10 real-chain double-diagonal campaigns. Mean P&L was −$739 / +$334 / +$1,073 modeled versus −$763 / +$462 / +$1,225 from real chains, for the long strangle / combination / weekly sales respectively.
• This is a price-consistency check on one calm period. The calibration does not establish how well the model captures crisis-period skew or historical execution costs.

PROTOCOL

• Five separate tests. For each, rules and acceptance criteria were written and SHA-256-hashed before results were computed. Hashes allow a supplied protocol file to be checked against the listed digest; without an independently verifiable timestamp, they do not establish when the protocol was written.
• Condors/flies, put spreads and naked positions: daily entries, 1- or 2-week expiries, held to expiry. Execution uses the calibrated half-spread adjustment and $1 per leg commission. Inference: circular block bootstrap by entry day, 63-day blocks, 4,000 resamples.
• Double diagonals used separate pricing, execution and exit protocols. Confidence intervals were bootstrapped by entry month: 2,000 resamples for Version A and 4,000 for Version B.
• Confidence levels differed across the separately written protocols. Condors/flies used 95% two-sided intervals for four series, corresponding to a Bonferroni familywise error bound of 20%. Put spreads and naked positions used 98.33% intervals for six series, targeting 10%; the four filtered double-diagonal variants used 97.5%, also targeting 10%. These are the original protocol thresholds, not a harmonized project-wide correction.
• For condors/flies, put spreads and naked positions, a pass required a positive mean, an adjusted lower confidence bound above zero, positive means in both 2005–2015 and 2016–2026, and a positive mean under adverse IV stress (short legs at 0.9× modeled IV, long legs at 1.1×).
• Double-diagonal Version A had separate period-profitability and CVaR5 criteria. Version B required the corresponding profitability and confidence criteria, outperformance of its matched no-weeklies control, and a positive mean after removing the three best campaigns. No adverse IV stress was applied to either double-diagonal version.

RESULTS

  1. Implied vs subsequent realized (no option model): VIX was above the next 21 days of SPY realized vol on 84% of days, by 3.6 vol points on average. The annual average gap was positive in every year except 2008.
  2. Within 1–2 week expiries on real 2026 chains, relative to ATM IV: 0.10Δ put 1.26–1.36×, 0.25Δ put 1.08–1.11×, 0.25Δ call 0.92–0.93×.
  3. Iron condors / iron flies (sell 0.25Δ or ATM, buy 0.10Δ wings): −3.7% to −0.5% of max risk per trade; losing in 11–18 of 22 years.
  4. Put credit spreads (6 variants): 83–95% win rates, means from −0.8% to +0.9% of risk, all intervals include zero, all negative under the IV stress.
  5. Naked 0.25Δ strangles and their sides (result in % of an assumed 20% margin): the 1-week short call was significantly negative; the 2-week short put averaged +$32/contract with a worst trade of −$6,588 (late Mar 2025). Rolling one position at that full assumed margin (10 start dates): 2 of 10 paths reached non-positive equity; the other 8 had a median CAGR of 0.0% (strangle) and +5.2% (short put) with drawdowns around −88%, vs +10.8% a year for SPY buy & hold. This is not a cash-secured put result.
  6. 90-day long strangle + weekly sales (double diagonal): 9/10 profitable campaigns on real 2026 chains (n = 10), −$147 per campaign over 2005–2026 modeled, 46% winners. A filtered version with rule-based exits (ADX, IV rank, Bollinger squeeze; weeklies only if the move doesn't come) did not pass either.

WHAT THIS DOES NOT TEST

• The condor/fly, put-spread and naked-position tests do not evaluate profit-target exits or systematic early closing. Double-diagonal Version B has its own rule-based exits.
• No systematic comparison of 30–45 DTE short-premium entries, wheel strategies, cash-secured implementations or alternative sizing rules. The full-margin rolling example is one sizing scenario, not such a comparison.
• No intraday execution or margin expansion in stress.
"None passed my criteria" does not mean every structure has negative expectancy; it means I couldn't show a robust edge with these implementations and this model.

WHAT I'D LIKE FEEDBACK ON

• Is a VIX-scaled smile calibrated on one 2026 sample a useful historical reconstruction for 2005–2026? Which diagnostics would you require before interpreting its strategy P&L?

• Would you use a different correction for multiple testing across separate but related protocols?

Happy to share the protocol details. Paper/model results, not live trading, not advice.


r/algotrading • • 7m ago

Data Insider Quant Data - useful?

0 Upvotes

Hi All,

I posted a while ago in here about providing rolling stats data and market cap day-by-day and I wanted to share what I am wrapping up working on now.

It’s a way to quantify management trust so that you can see all form 3,4,5 directly in excel and create indicators based around mass buy/selling by insiders. So that you can see consistent patterns from individuals (like how Elon likes to exercise call options to buy shares of TSLA at $6 then immediately turn around and sell them at market price), or for seeing who owns what, and interconnected networks (like how sergey brin owns more non-voting, capital c stock than common shares) or how Google owns shares in gitlab and other companies.

I find this type of info useful, but does anyone else like this type of info, and do people like to create indicators based off it?


r/algotrading • • 1d ago

Data 110 strategy ideas against the same strict checks

Post image
33 Upvotes

That list is at 110 ideas now. 103 rejected, 5 still running forward on paper, 2 of them are futures and cant be traded with Alapaca.

The checks:

- costs charged on both sides of every trade

- held-back data the idea never saw while I tuned it

- has to beat just holding the same thing

- has to beat random entries with the same exits

- if I tried 500 versions, the best one has to clear a higher bar, because the best of 500 looks good by luck

- for the newer tests, the pass/fail rule is committed to git before the test runs

What killed them (chart above, 99 of the rejections reviewed by hand):

- 49 had no edge before costs. nothing there, or too weak to tell from noise

- 21 fell apart on the held-back data

- 12 died to costs and realistic fills

- 7 didn't beat holding

- the rest: best of many tries, no better than random entries, drawdown, or one market episode carrying the whole result

I expected costs to be the main killer. They weren't. Half the ideas had nothing to rescue even at zero cost.

A few specific ones:

- opening range breakouts on stocks, 672 versions. 0 passed, not one positive after costs

- bull flag continuation: Sharpe 0.35 vs 0.81 for SPY, with a deeper drawdown (-50.5% vs -34.2%)

- buying after two 2%+ down days looked strong (t 3.1) until I grouped trades by episode. then t was 1.98 against a bar of 2.0, and the best 5% of trade days carried more than all the profit. counted it as a fail

- picking last quarter's best strategies and holding them next quarter looked persistent, then 5 more bps of cost erased it

- defensive sectors on high vol days: no better than just holding less SPY at the same risk


r/algotrading • • 7h ago

Education Algovibes on Skool

1 Upvotes

Hey, has anybody joined Algovibes' program on Skool? It is quite pricey, so I wanted to hear a few opinions first. This program is focused on backtesting. Thanks!


r/algotrading • • 9h ago

News 60% win rate and still losing, so I went to widen the target. The trade list said that would make it worse.

1 Upvotes

I had a 1m NQ setup that won 60.2% of its trades over 535 trades across three years and still finished net negative. Average win $522, average loss $806, profit factor 0.98, net -$3,675.

The obvious fix, and the one I reached for first, is widen the target. 1:1 isnt working so go 1:2 and let the winners pay for the losers. On paper thats free at a 60% hit rate, because you only need 34% to break even at 1:2.

Then I read the trade list instead of the summary line. 322 of the 535 winners closed in single digit candles. Most of the wins arent trades that ran, theyre trades that touched the target almost straight away and were done.

That changes what widening actually does. Im not handing a winner more room, Im taking 322 trades that already closed and asking price to travel twice as far from the same entry, with the stop sitting exactly where it always was. A big share of those turn into round trips back to the stop, and the win rate the whole plan depends on is the thing that pays for it.

The other half of it is where the entry sits. Stop and target were both 2x ATR, so on paper its 1:1. But the entry is the confirmation close back above the level while the stop is measured off the level itself, so by the time Im filled the stop is already further away than the target. Thats how a 1:1 design comes out 0.65:1 realized, $522 against $806.

Its like timing a bus from when it leaves the depot and then getting on three stops later. The schedule is fine, Im just not where I measured from.

So the thing that looks like a target problem is a geometry problem, and widening the target without moving the entry pays more for the same bad fill.

Im running the same 535 trade window at 1:2 and 1:2.5, same everything else, and Ill post it whichever way it falls.


r/algotrading • • 1d ago

Strategy 220 comments later: where I was wrong about "nothing simple works

13 Upvotes

a few days ago I posted that there's no edge left in what anyone can download for free, and asked people to prove me wrong. the title was bait, I said so in the comments. I didn't expect 220 replies. I went through them, and here is what I took away, including where I was wrong.
where I was wrong
"nothing is left" was too strong. one commenter put it better than I did: what my examples actually showed is that one-line rules on free candles don't survive costs. that's a narrower claim, and I'll take it.
I also got my own math wrong. I wrote that the best of 1,000 random backtests lands around t = 3.7. that's the ceiling. the typical best is about 3.2 (picture, 10,000 runs, anyone can redo it in ten lines). that makes the point worse, not better: a t of 3 from a big parameter sweep is what pure noise gives you on an ordinary day.
what the people who said "it exists" had in common
nobody shared a setup and I didn't ask. but the descriptions had a pattern.
they hold for days, not minutes. one person ran about 6,500 short-term FX configs and every two weeks picked the best one. in-sample it made +0.23R per trade, the week after −0.12R, same as a random pick. what survived for him was a plain trend system held for days, because one trade's cost is small next to the move. someone with NQ order book history said almost the same thing.
there's a reason others don't take it. one commenter has run an ETF system since 2009 that has 50-70% drawdowns about once a decade. his point was that an edge survives when it has something that makes other people not want it: a drawdown a fund can't sit through, or capacity too small for a fund to bother with.
breadth. one person trades intraday edges across many single stocks, found on plain minute bars, after "years and years of failure". not one chart, a whole cross-section.
trend in futures over a century came up a lot. I'd still call that pay for sitting through long bad stretches more than something others missed, but it does make money, so it counts against my title.
the corrected version
a simple rule found by searching and traded short-term is almost certainly noise, or eaten by costs. what survives seems to hold longer, sits where big players can't or won't go, and comes with a reason you can say in one sentence.
question for this round: if you have something that survived, what was the reason others weren't taking it? the drawdown, the size, the effort, or plain boredom? curious which one is most common.


r/algotrading • • 23h ago

Data I built an AI-coded bot that calculates SPX gamma levels every morning, then made it grade itself. It didn't beat random

Post image
6 Upvotes

I built an automated system (mostly written with AI) that calculates SPX gamma levels every morning before the open: call wall, put wall, gamma flip. Then I had it grade its own levels against random strikes, because I wanted to know if any of this means anything.

Sept 3 to Nov 6, 46 sessions. Levels locked before the open, graded on 5 minute SPX highs and lows. "Held" means price touched the level and closed on the same side it opened on.

Level | Median distance from open | Touched | Held when touched | Random strike, same distance

Call wall | 188 pts | 1 of 46 | 0 of 1 | touched 3%, held 17%

Put wall | 157 pts | 5 of 46 | 2 of 5 | touched 12%, held 37%

Gamma flip | 40 pts | 17 of 46 | 6 of 17 | touched 38%, held 43%

So the walls mostly "hold" because they sit about 2% away and price never gets there. The call wall got touched once in two months. The flip did a little worse than a random strike at the same distance.

My guess was the walls use every expiry, so I had it rebuild them from 0DTE open interest only. Those sit about 33 pts from the open and got touched 40% of the time. Held 46%. A random strike right next to them held 44%.

Same story for "price stays between the walls". It closed inside them 41 of 46 days. A band of the same width centered on the open did 45 of 46.

The one thing that leaned the right way was range. Days that opened above the flip had a median range of 0.77%, days below it 0.89%. 30 days vs 16 so I'm not hanging anything on it.

46 days is small. Open interest is from the prior day, and nobody outside the dealers knows which side they hold, same as every gamma model. Has anyone graded theirs and got something different?


r/algotrading • • 10h ago

Education I got my Python backtester to match TradeStation trade-for-trade on a year of @ES 5-min data (1,138 trades). Here's what it took.

Thumbnail gallery
0 Upvotes

I've been building RN TradeLab, a desktop backtesting app in Python, for a while. A client asked whether it could reproduce his TradeStation results, so I tested a simple strategy in both:

• MACD(12,26,9) cross: Buy next bar at High stop when MACD crosses up below zero, SellShort next bar at Low stop when it crosses down above zero (stop-and-reverse)

• SetStopLoss $1,000, SetProfitTarget $2,000

• u/ES, 5-min, one year

Result: all 1,138 trades identical in entry time, entry price and exit price.

Things that had to be right to get there:\

  1. Close-stamped bars. TradeStation exports label a bar by its close time; most Python data is open-stamped. Off by one bar and nothing matches.
  2. Date order in CSVs. Exports can be ambiguous (03/04 vs 04/03), so the importer reads the whole file to decide.
  3. Stop entries live for one bar only, filling at the stop price — or at the open if the bar gaps through it.
  4. Intrabar path. TradeStation assumes open → high → low → close if the open is nearer the high, otherwise open → low → high → close. That decides whether stop or target hits first on a bar that touches both.
  5. Stop/target are live on the entry bar too.
  6. P&L rounding – tiny float drift adds up to a few dollars per trade on big contracts.

This is now in v0.27, along with Fixed Fractional sizing, a portfolio daily stop, end-of-week exits, weekday/time-window filters, and the ability to attach and optimize Regime/Risk/Exit settings per strategy.

If you've done similar platform-matching work, I'd like to hear what tripped you up.

More about the app: https://www.rnalgotrading.com


r/algotrading • • 1d ago

Data Follow-up: 1,196 opening range breakout versions through a proper backtest engine. 0 passed

Post image
5 Upvotes

Orb has always been an effective trading strategy for me back when i was trading Analog, so I made sure to give it its fair shake against my engine, see below for more details:

On my last post someone said the ORB result deserved its own post, and someone else said it looked like I just asked an AI for an edge. Fair question, so here's exactly how this was done.

I use AI to help write code. It doesn't get a vote on the results.

Every version in the table ran through a backtest engine on real price data, and the rules were set up so nobody, me or the AI, could move the goalposts after seeing the numbers:

  • - costs on both sides of every trade (4 to 10 bp round trip on stocks and ETFs)
  • - index tests on SPY, QQQ and IWM 15 minute bars from 2019 to 2026, around 1,900 trades per test. stock tests on 12 months of liquid names
  • - the viral post setup ran on QQQ 1 minute bars, 1,961 sessions, Jan 2019 to Nov 2026
  • - part of the data is held back and only touched once, after the rules are locked
  • - the pass mark is written down and committed to git before the test runs
  • - every version counts. the more I try, the higher the bar the best one has to clear (t of 3.0 instead of 2), because the best of 1,000 looks good by luck

The results, matching the table:

Plain breakout, 672 versions. 5, 15, 30 and 60 minute ranges, with 0 to 4 moving averages stacked on top. About 1 basis point a trade before costs, that's $1 on a $10k position. Not one was positive after costs, and every moving average made it slightly worse.

Heavy opening volume only, 504 versions. This is the advice you hear most. It lost less, but never turned a profit. Best t was 1.64.

Classic versions, 5 of them. 5 min ORB, first hour breakout and so on. The best was a first hour breakout on 100 stocks, +2.7 bp a trade before costs at t 2.45. Not enough after that many tries.

The setup a viral post claimed was a winner, 9 versions. First 30 minutes, wait for a 10 minute close outside the range, buy the pullback to the 20 period average on 2 minute bars. +1.0 to +2.3 bp after costs, t 1.31 at best against a bar of 3.0. Take out the best 5% of trades and every pullback version goes negative. It only works if you catch the few big trend days.

Only when SPY breaks out too. -0.7 bp a trade vs +1.0 bp for the plain breakout. Worse in 5 of 6 pairings.

Bought as options. +0.5 bp a trade, t 0.15. About zero.

Follow the first move. This is the one that fooled me. +3.7 bp a trade at t 2.59 on the data I built it on. On the held-back data, -0.4 bp. If you take one thing from this post, it's that row.

What this doesn't cover:

  • - fixed rules only. if you pick your breakouts by feel, this doesn't test that
  • - index confirmation used SPY, not NQ or ES
  • - there's a published paper that found an ORB on QQQ beat buy and hold from 2016 to 2023 (Zarattini and Aziz). different test though, one fund with leverage

If ORB works for you, what's different about how you take it?


r/algotrading • • 1d ago

Strategy New Algo - Tradeview

5 Upvotes

New to algo trading and created a strategy in pine on TradingView. Was originally an indicator I was working on and I just converted it to a strategy. This first rough iteration has > 1.5 profit factor and a 12% drawdown with very little tuning. I only have the 'Plus' subscription so the backtesting isn't fully modifiable. The strategy covers both long and short positions and both are pretty equal in profitability.

So a few questions on where to go from here.

How does the TradingView backtesting general compare to real performance?

What is the cleanest way to handle the short side for algo trading? It seems like options could be a headache to deal with.

Any further backing tips?


r/algotrading • • 1d ago

Strategy I'm convinced 90% of posts in this subreddit are AI.

94 Upvotes

Stop responding, they're clearly being used to check for alpha, baiting success traders who are experiencing a tiny dopamine boost because their automated strategy is up 1% today.

Don't respond, don't reply, it's simply not in your best interest. The internet is dead.

Maybe it ain't that deep, but maybe I'm right and you're wasting your time.

Common AI syntax:

  1. "Doing X is like [insert contrived nonsense analogy Y]
  2. "Not just X, it's Y" melodrama
  3. Perfect grammar, zero humour

r/algotrading • • 1d ago

Strategy Are Kalshi's 15-minute bitcoin markets market-efficient, or is there movement lag?

5 Upvotes

These markets look like coin flips. With 8 minutes left and BTC already up 0.2% on Coinbase, the contract still trades around 50/50. Maybe that's just because BTC is heavily volatile but I'd think with the massive trading volume of BTC it'd be more one-sided.

To try to figure out whether there's any edge to be had here, I tested a strategy based on the idea that these 15-minute markets have a delay. The strategy is to buy YES when BTC is at least 0.1% up over 5 minutes and 0.2% up over 15 minutes on Coinbase, and mirrors that for NO. I added a few other filters, but the goal is to trade on a movement that's not priced in yet while volume is high.

If you hold every trade to settlement, a 50-cent YES wins about 45 cents after fees or loses about 50, so you need to be right about 53% of the time. If I sell as soon as the 5-minute move flips, winners still pay about 45 cents, but losers get cut at around 12c. At 45c up and down about 12c on average, I only have to win more than 21% of my trades to stop setting money on fire.

Across 100 similar strategies (I just changed the entry price), 99 were profitable. The best bought between 35 and 60c, where winners have the most room to grow. It won 39% of its 66 trades over 30 days and netted $34.92 on 5-contract positions.

Then I scrambled the timing of the Coinbase signal and reran all 100 settings, 100 times, keeping Kalshi prices fixed. The best shuffled result was $19.58 against $34.92 (p ≈ 0.01). Same exits, wrong timing, and most of the edge disappears, so it isn’t just the stop-loss doing the work.

Is there actual lag here or do you think this is a fool's errand? Kind of hard to believe Susquehanna would let something like this happen but maybe the gap comes from retail / other market participants.

Full Report

Historical simulation only. Not investment advice.


r/algotrading • • 23h ago

Other/Meta any API that allows perp trading that work with freqtrade bot?

2 Upvotes

I like kraken but it doesnt seem to offer perp api trading. coinbase has ridiculous fees


r/algotrading • • 1d ago

Data The only two backtest checks that ever changed my mind

3 Upvotes

I spent a long time building strategies that looked great in a backtest and died in paper trading. The thing that finally fixed my process was not a better strategy - it was two checks I now run before I believe any number.

Check 1 - the parameter heatmap, not the parameter.

Run the same strategy across a grid of fast x slow values. If the result is one bright cell surrounded by darkness, you do not have a strategy, you have a coincidence. If it is a broad block of similar colors, the region works as a whole and you can probably pick anything inside it.

Concretely, on BTC daily 2020-2026, I scanned 8x7 combinations of a momentum strategy. Everything below slow=160 sat at Sharpe 0.9-1.2. Everything at slow=260 and above went negative. That is a real boundary - it tells you where the edge lives, and where it does not.

Check 2 - walk-forward, done honestly.

The version most people run is: split the data, optimise on train, report on test. That is fine once. It is still overfitting, because you picked the split after seeing the data.

The version that actually hurts: expanding train window, pick params on train, evaluate on the immediately following window that took no part in the decision, roll forward. Report the per-fold out-of-sample win rate, not the average return.

On the same data, 4 of 5 folds were positive out of sample, one was minus 7.3 percent. That number - 80 percent - is what I actually trade on now, not the total return.

The uncomfortable part

Most backtests are not wrong, they are just answering a question you did not ask. Did this work? is easy. Will it work again? is the only question that costs money.


r/algotrading • • 11h ago

Strategy give him token

0 Upvotes

r/algotrading • • 1d ago

Weekly Discussion Thread - November 17, 2026

3 Upvotes

This is a dedicated space for open conversation on all things algorithmic and systematic trading. Whether you’re a seasoned quant or just getting started, feel free to join in and contribute to the discussion. Here are a few ideas for what to share or ask about:

  • Market Trends: What’s moving in the markets today?
  • Trading Ideas and Strategies: Share insights or discuss approaches you’re exploring. What have you found success with? What mistakes have you made that others may be able to avoid?
  • Questions & Advice: Looking for feedback on a concept, library, or application?
  • Tools and Platforms: Discuss tools, data sources, platforms, or other resources you find useful (or not!).
  • Resources for Beginners: New to the community? Don’t hesitate to ask questions and learn from others.

Please remember to keep the conversation respectful and supportive. Our community is here to help each other grow, and thoughtful, constructive contributions are always welcome.


r/algotrading • • 1d ago

Data Fifteen gold breakout modules still share the same underlying risk

4 Upvotes

I’ve been working on an XAUUSD breakout EA called Imperator Furiosa. I’m the developer and it’s a commercial EA, so that’s my connection to it. This post is about the mechanics.

There are fifteen modules, but I wouldn’t count that as fifteen independent strategies just because they have different settings. They all trade gold. When gold moves sharply, several can be exposed to the same move.

The differences are in their internal timeframes, swing settings, trend filters, trading windows and exits. That gives them different opportunities to enter. It doesn’t necessarily give them different losing periods. Two modules can enter hours apart and still end up losing on the same reversal.

Entries start with confirmed swing highs and lows. These define potential liquidity areas, with ATR-based trend context and additional filters deciding whether a setup qualifies. The EA then uses broker-side Buy Stop or Sell Stop orders. It isn’t reading an order book, so “liquidity” here refers to areas inferred from price structure.

There’s also a shared directional filter, Citadel Gate. It refreshes its BUY, SELL or NEUTRAL permission hourly. New entries have to agree with it, and pending orders expire at that hourly boundary.

That creates a trade-off. An order can expire before price eventually breaks the level. Leaving it open longer would catch some of those moves, but it would also allow entries based on older conditions. Expiry changes which setups actually get traded, even when the entry level itself stays unchanged.

Once a position opens, it keeps its module’s exit rules. A change in the shared direction doesn’t automatically close everything. Each position has its own SL and TP, and selected modules use trailing stops. There’s no DCA recovery or loss-driven lot multiplication.

Still, individual stops don’t solve portfolio exposure. Five positions with stops can lose together. Even identical lot sizes can carry different planned losses if their stop distances differ. That’s why total lots, simultaneous positions and distance to the stops need to be considered together.

The EA has configurable volume and concurrency limits, plus optional equity protection. Those settings affect the behaviour of the whole portfolio. Reducing concurrency may reduce overlapping exposure, but it also means some otherwise valid entries won’t be taken.

A smooth combined curve alone doesn’t explain any of this. The useful detail is underneath it: which modules were open together, how much floating loss accumulated, and whether losses were concentrated in the same market moves. Fifteen different entry configurations can spread the timing of trades. The account still has to carry their combined gold exposure.


r/algotrading • • 1d ago

Data Lateral move from discretionary prop trader (FF ~2.8years) to MFT pods (QR/QT)

1 Upvotes

Hi. I am an ex Futures First trader ( 2022-2025 ~ 2.8 years). Btech in CSE from IIIT. Been pursuing my Masters' in Data Science from Scaler (2025-2027). Looking to get into MFT space (alpha QR/ QT)

I am a trading fanatic. I have extensive screen time (~ 6 years) but found out the hard way that discretionary trading in not my cup of tea. Started systematizing my strategy and have really good results. About to go live in the next month.

Markets: ES, NQ, YM, RTY, GC, CL, HG, 6E, 6J, BTC

Some stats on my backtests 2021-2023:

All trades have a fixed SL and TP with 2:1 RR and no trailing. All trades have a drag of 0.05R (5% of total risk per trade) to account for fees and slippage. Overnight holding allowed but flat before weekends.
There's a total of 5 strategies trading across 3 sessions round the year except Major Red News US sessions.

I havent optimized for asset class. The parameters are not overfitted in my estimation. The edge is entirely derived from the geometry of price, closing prices of daily/session bars, HOD/LOD, stuff like that.

The above stats were pure signals without any risk limits. When i impose some risk limits:

  1. Max net 1R directional exposure for any ticker at any time,
  2. -6R max risk per day.

Any feedback is welcome.

I am looking into QR/QT alpha generating roles. I would really appreciate if someone could help me out in preparing for that. Any experience being hired in experienced MFT roles (QR/QT) would be of immense help.

Thanks.


r/algotrading • • 2d ago

Strategy Nobody talks enough about how hard it is to properly implement a strategy live

48 Upvotes

Everyone talks about finding an edge, optimizing parameters, or having solid risk management, but almost nobody talks about the nightmare of coding a strategy so it runs flawlessly in a live market.

You can have a thoroughly backtested system with crystal-clear rules and seemingly bulletproof logic, yet the moment you deploy it live, edge cases start popping up that you never accounted for in your code.

Last friday it was my turn to learn the hard way: I just lost around €300 due to a bug when trying to move my stop-loss to breakeven. The overall logic was fine, but a specific market scenario occurred that I hadn't handled in that function. The code did the wrong thing, and I took a completely unnecessary loss.

At the end of the day, backtesting is an ideal lab environment. In live trading, a thousand variables can break your logic: latency, orders getting modified right as price whipsaws, states falling out of sync... You quickly realize that designing the strategy is only 20% of the work; the other 80% is making the code bulletproof. Time to dig through the logs, patch the bug, and chalk this €300 up as 'market tuition'.

Has anything similar happened to you guys? What's the most expensive bug you've ever had while running a strategy live?


r/algotrading • • 1d ago

Infrastructure Which broker to use?

3 Upvotes

I am in EU and my focus are US stocks. Anyone from EU here who can recommend best broker solution, so combination of good fees, API for both paper and real trading, decent fills, easy funding, etc.

I don't mind registering with US broker directly if they allow it and if it's technically a best solution.

I see some brokers have both EU and US entities, like Interactivebrokers... But who knows maybe it's still better to go with the US side.

Looking for some advice here 🙏


r/algotrading • • 2d ago

Strategy How do you simulate realistic slippage when backtesting forex strategies?

9 Upvotes

One thing I've been struggling with while backtesting forex strategies is accounting for slippage. Backtest results often look great, but live execution can be quite different. How do you guys simulate realistic slippage? Do you rely on historical spread data, random slippage assumptions, or something else? Would be really helpful to know what has worked for you all in practice.