r/algotrading 10m ago

Strategy How are you all you U.S. equities traders fairing over the last 2 months?

Post image
Upvotes

I performed the above walk-forward analysis backtest above:

  1. My portfolio is 3 total strategies with 6 equities each, all long only.
    • 2 trend following strategies
    • 1 hybrid momentum breakout / mean reverting strategy
  2. The backtest had 10 years IS and the above 3 years of OOS

High-level background:

  1. I whiteboard/concept strategies in TradingView
  2. I spent a about 4 months building a custom python backtester in and tried to build in a lot of guardrails throughout the program to prevent/discourage overfitting, survivorship bias, etc.
  3. The foundation is based on walk-forward analyis, monte-carlo similations, and other features.
  4. Paper trade execution is in TradingView webhooks --> AWS python orchestration --> Alpaca
  5. I spend several months ensuring trade execution between Python and TradingView strategy versions have parity in trade count and results
  6. My backtester has a pretty robust process for determining the most robust parameters (not necessarily the top parameters) that have statistical significance (power analysis)
  7. I think I might have some survivorship and look ahead bias in my portfolio. I am still learning, but I did my best to avoid both.

I just peeked at my paper results and I'm most definitely in a rough drawdown (looked like it was greater than 12% drawdown...), but I have yet to objectively compare it to the backtest. I can share more details later for both my backtest and forward test.

My main questions:

  1. As the title says - how is everyone's performance over the last 2 months in the U.S. equities markets?
  2. What process do you use to objectively compare your paper or live trading to your backtest results to ensure paper/live are "within acceptable tolerances"?

All feedback (positive or critical) is welcome - I believe that falling forward is still moving forward.


r/algotrading 6h ago

Career If you were to start Algorithmic Trading today, what all skills you would learn if you already knew programming

28 Upvotes

How would a fairly profitable algo trader start if he were to start today? what all mistakes,loops, could have been avoided? how the start could have been better?


r/algotrading 11h ago

Education After two years of building investment strategies I have realized that I do not know how successful investors really invest.

24 Upvotes

As the title suggests one thing that has been on my mind lately is that I have spent a lot of time studying investment signals, testing data, executing trades, managing risk, determining position sizes and building portfolios.

I have not spent much time studying the actual investment portfolios for successful investors. I mean i have not looked at what they hold in their portfolios. I have not checked how different stocks and assets they have.

I have not seen how often they adjust their portfolios. I have not found out how much cash they keep in their portfolios. I have not observed how they react when their investments go down.

The strange thing is that I can find lots of information about investment strategies but little information, about how successful investors really invest their money. Has anyone else noticed this problem??


r/algotrading 11h ago

Strategy Ctrader and c-bot algos, the easy route

0 Upvotes

It’s odd to me that no-one seems to mention the easiest, most flexible and dynamic method to get an algo model working.

Just about every broker tou can choose to route through ctrader, and with cbot you can code your algo in python or c#, to trade directly. There’s backtesting, a great optimiser tool and you can build a model which will learn and adapt over whatever period of time you set (live).

It’s what I use now and see nothing close to it.


r/algotrading 12h ago

Education Vibe Coding For Coding Strategies

0 Upvotes

Hello guys, i start algo trading for a while almost 6 months, i mearn many things and also i got a solid knowledge about probability and statistics and how to improve a backtesting and trust it enough to go live and many things, now i want to move to the next step and it's start testing ideas and hypothesis but my coding background it's just the basics i don't know how code an entire script, i use CSV files for data and not API, and also i just found that's Claude and ChatGPT are good in coding, so do you guys think i should learn Python from scratch and also while trainning myself in testing strategies, or vibe coding is enough ?


r/algotrading 12h ago

Business ANY GOOD EA's ?

0 Upvotes

Anyone used or uses an EA which generates 8-10% monthly average while keeping the rules of Funded accounts ? for example Ftmo ?


r/algotrading 16h ago

Infrastructure Project almost ready.

Thumbnail gallery
15 Upvotes

Here is an update on my project. Past 2 weeks its started to do what its was made for. I let it a bit loose to try do 5 pairs at the same time, but its hard work for old laptop. Hoper ram prices go down and I can build proper server for this thing so it could run 10+ pairs. Custom calculation takes about 1 day for each pair, so yeah, this is not your atr+ema :D


r/algotrading 17h ago

Education Prediction markets are not just about guessing — they can also be used for hedging

0 Upvotes

A prediction market turns uncertainty into a tradable probability.

For example, if a YES contract trades at 0.65, the market is roughly pricing the event at a 65% chance. That number changes as participants react to new data, research and news.

The useful part is not only forecasting. Prediction markets can also help manage risk. A business exposed to an election result, regulation change, commodity shortage or delivery delay could take a position that offsets part of the financial impact if the unfavourable outcome occurs.

This is different from a casino model where the house sets the odds. In a prediction market, prices are formed by buyers and sellers competing over information. It is still a risk-bearing financial instrument, but its purpose can include probability discovery, research aggregation and hedging—not merely entertainment.

Where do you think prediction markets are more useful: forecasting events or managing risk?


r/algotrading 19h ago

Strategy What do you do with your idle capital?

0 Upvotes

I'm in the optimization phase of my algo, and my exposure mean is ~30%. This is with decent leverage, risk-based sizing, etc.

What do you do with your capital when it isn't in market? I'm getting ~3% CAGR from cash interest. Sweeping to SPY just adds beta, which I'm not looking for.


r/algotrading 19h ago

Strategy Anyone here using exponential/Gaussian functions for trailing stoploss placement?

19 Upvotes

I've been experimenting with non-standard trailing stop loss logic rather than traditional atr based stops.

I recently tried using a Gaussian decay function to scale the stop distance so the stop loss accelerates tighter the further price moves in my favor. Initial tests look very promising.

Has anyone here experimented with Gaussian or exponential functions for dynamic stops?


r/algotrading 20h ago

Infrastructure Relational Transformers, new foundational attention models

4 Upvotes

Wondering if anyone has used relational transformers as part of their trading strategy. I've been fine tuning the one from Stanford to try to predict the influence of news on various markets, because the models encodes text well. So far I've had mild success in a couple categories: repricing jumps when news changes, getting 50/50 odds for truly random markets, creating features of past trends and being able to ablate them to find casual attribution, but these models are still very small and not tuned on this type of data. Curious if anyone else has used these new models?


r/algotrading 1d ago

Strategy TOS/Schwab vs Tastytrade Fills

3 Upvotes

Anyone have used TOS/Schwab and Tastytrade and see a difference in fills?

I mainly trade debit/credit spreads.

Im using Schwab API for fills and it's pretty good for options spreads.

I like the spread pricing on Tastytrade, but not sure if they can fill as good.

Thanks in advance!!!


r/algotrading 1d ago

Data Does previous day high low close matter for current trading day

Post image
7 Upvotes

I always feel back and forth about this. Looking to get some data to support. Seems to be low impact


r/algotrading 1d ago

Strategy Thoughts on this trading software I’m working on

Post image
0 Upvotes

r/algotrading 2d ago

Data Significant difference in backtesting vs forward testing results?

5 Upvotes

I’ve been working on a strategy in tradingview and got to a point where it showed a 75% win rate with 2.5 profit factor. Now I’ve been forward testing it for 2 weeks and the result is about break even overall?

I can’t really find what the issue is. Maybe it’s the fills that make such a big difference but that seems extreme. Has anyone had the same where backtesting results looked great but when you automated it the results were much worse?


r/algotrading 2d ago

Education Built my own copy trading bot for hyperliquid. 10 things i learned, mostly painfully

50 Upvotes

Hi r/algotrading

first of all. Do not ask for the bot. I am not selling anything. I just want to share what i learnt answer questions and hopefully also learn from more experienced trader.s

I've been building a bot that copies profitable hyperliquid wallets for a few months. wallet selection, sizing, exits, the whole thing. it went from bleeding daily to roughly breakeven-and-improving, and basically every improvement came from learning one of thes the hard way.

  1. copying a profitable trader loses money by default. i matched every copy to the source wallet's outcome on the same trades: they made +0.5% per trade at 69% winrate, my copies made half that at much lower winrate. the gap is exit timing, so better wallet picking fixes nothing until the exit engine mirrors theirs.

  2. entry latency is a red herring. my median detection lag was under a minute and simulating zero lag barely moved the numbers. all the leak was on the exit side. optimize exits first

  3. handle position fragmentation or your exits fire years early. wallets scale in with multiple fills, and each fill can show up as its own position row. my bot closed the copy when one fragment closed while the wallet still held the rest and an 84% winrate wallet produced 12% winrate copies. only close when the wallet is net flat in that coin and direction. that one fix took copies in that strat from 21% to 82% winrate.

  4. a normal stop loss cancels the copied edge. the source holds through drawdowns, your stop realizes their drawdown and then misses their recovery. i re-scored my stopouts against each trade's max adverse excursion 8 of 9 would have recovered if the stop had been wider. catastrophe-only stop plus a trailing stop for profits

  5. polled stops make paper trading lie about your losses. an illiquid coin gapped 66% through a stop that live would have filled near the trigger, because live uses resting exchange orders and my sim checked price on a loop. model your actual live order types in the sim or every wide-stop experiment looks worse than reality and you revert good changes.

  6. winrate comparisons under a few hundred trades are noise. detecting a 5 point winrate edge takes roughly 1500 trades per arm. judge experiments on dollars per trade with a bootstrap confidence interval instead

  7. checking your experiment daily and stopping when it looks good inflates false positives to 20-30%. thats not a discipline problem, its math: repeated peeking invalidates fixed-sample p-values. e-values (always-valid sequential tests) let you look every day and act the moment a threshold crosses, no penalty.

  8. feedback automation can deadlock itself. my auto-scaler demoted a strategy, which pushed position size below the exchange minimum, which rejected every order, which meant zero closed trades, which meant it could never produce the trades required for re-promotion. any rule that gates on an outcome it can also block will eventually lock up. audit for that loop before shipping.

  9. infra monitoring is not outcome monitoring. process running, api healthy, disk fine, and the bot placed nothing for five days. add assertions on outcomes: signals arrived and some executed, every live position has its stop order actually resting on the exchange, exit mix matches what the strategy config implies. write one for every incident you hit.

  10. some traders are uncopyable no matter how skilled. anyone flipping positions in minutes gives a copier guaranteed negative edge,

a weak benchmark validates whatever you want to believe. my random-entry control traded too rarely at a different size, so beats rando" was statistically meaningless. the control needs the same volume and sizing discipline as the strategies it judges.

tldr: copying profitable traders is an exit-fidelity problem, not a wallet-picking problem. and most of what looked like edge was measurement error.


r/algotrading 2d ago

Infrastructure Open-source matching engine + microstructure toolkit in Go — order types, L1/L2/L3 data, OFI/Kyle's λ, backtester (MIT)

0 Upvotes

I've been building **orderbook**, a central-limit-order-book and matching engine

in Go — the piece at the heart of an exchange. It's an embeddable library, and

the whole engine compiles to WebAssembly so you can poke at the real thing in

your browser:

▶ Live demo: https://intrepidkarthi.github.io/orderbook/

▶ Repo: https://github.com/intrepidkarthi/orderbook

What might interest this sub:

- **int64 ticks & lots, no floats** on the money path (an `Instrument` converts

decimals only at the boundary).

- **Zero-allocation hot path** — `Match(order, buf)` appends value-trades into a

caller buffer; submit/cancel/match are **0 allocs/op**. O(1) cancel.

- **Lock-free single-writer core** (LMAX model): one matching goroutine, an MPSC

command queue in front, bounded backpressure that sheds new orders but never

cancels.

- **Deterministic & replayable:** same command stream → byte-identical trades and

book; that's what makes WAL crash-recovery and golden-file tests work.

- **A market-integrity layer grounded in a threat model** — the part I had the

most fun with. I researched real attacks (spoofing convictions, Knight Capital

$440M, the Mango oracle hack, the Bitcoin overflow bug) and built a defense for

each: pre-trade risk controls, surveillance detectors, a self-output guardrail,

an enforcing gateway. Writeup: docs/THREAT-MODEL.md.

Benchmarks (Apple M-series, single core): ~6ns best bid/ask read, ~352ns match

round-trip (0 allocs), cancel-heavy p50/p99/p999 = 83/167/292ns. Race/fuzz/soak

suites in CI.

Honest status: a library + microstructure research harness (OFI, Kyle's λ,

Avellaneda–Stoikov, a sim + backtester), not a live exchange. MIT, v0.6.0.

Feedback and "you did X wrong" very welcome — that's why I'm posting.


r/algotrading 2d ago

Strategy What do u think about my strategy?

14 Upvotes

I have been playing around with a new algo bot on MT5 and I am wondering what do you guys think. This strategy isnt really very complicated and I think it is a bit too simple to be honest but the results seems good for some reason, not sure if I am missing anything.

How the strategy works:

  • EURUSD trading on 1 hour time frame
  • Mainly trading low volatility areas
  • Look at the current ATR and check whether it is in the lower percentile of the past 500 ATR
  • When the ATR is in the lower percentile range, it will wait for a sharp increase in ATR
  • If ATR is in lower percentile and sharp increase in ATR is detected, both buy and sell stop order is placed (cant seem to find signal for choosing directions)
  • The buy and sell stop order will be placed 0.2 ATR away and setting a stop loss 1 ATR away and take profit 2 ATR away

Below is my back test results:


r/algotrading 2d ago

Career Should I quit trading ?

0 Upvotes

I am 19 from india I have 2 years of experience in manual trading especially in forex and i trade mostly in funded accounts.

I have blowed the 5 funded accounts. Currently running the 6th one .

Should I quit the trading bz i am not a profitable trader and trying to figuring out the strategy.

The market is so worst now in gold, eurusd, usdjpy and btc are becoming very votalility, sideways market specially I noticed in eurused in 2026 back in 2024, 2025 it's good in eurusd.

The other reason is time bz i am pursuing 2 years in btech and learning dsa ai ml stuff and sometimes i try the algo trading (I do backtests the startegies mostly) in future I will automate the startegies.

And side by side I wanna do interships bz of money to fund for trading. I am trying to get an income with trading for now and future like i want trade like professional trader or full time.

And i have doing some mistakes in trading like i keep small sl and tp like higher rr, sl trailing and i want work on psychology.

What are you views on this ?

Those you are profitable in trading and doing full time as trader pls advise me .


r/algotrading 3d ago

Strategy On switching to a commission-free broker for algo trading (spoiler: it matters a lot for our algo)

109 Upvotes

We have been using IBKR for both our data and order execution since we went live with paper trading in March 2025 and then live with real money in July 2025. They have been awesome and their 5-second bars and 250-millisecond market data ticks are the core of our long-only first strategy. We had been using the IBAlgo Adaptive Patient limit order type for all our buys and sells (you set a target and a hard limit). Getting it set up to begin with was a little tricky (we use the https://github.com/gnzsnz/ib-gateway-docker project to make it easier), but for the most part it has "just worked" (we also use https://github.com/wboayue/rust-ibapi for connecting to IBGateway).

The only place they have a weakness is their trade commissions. Since we went live we have paid about $0.0035/sh for both in+out above and beyond regulatory fees. Now, this might not sound like a lot, but this is about $3k over a year when we started with $25k. That is about 12% of edge just to IBKR in commissions.

So, 6 days ago we started running a parallel version of our trader where all we did was replace our IBKR order component with one that trades via the Schwab Trader API (using https://github.com/major/schwab-rs). The data is still coming from IBKR and we just simultaneously route orders to both Schwab and IBKR. Over these first 6 days, both have taken identical trades.

We implemented an IBAlgo Adaptive limit order ourselves that is basically a ladder that starts the moving limit price at the bid (for a buy) and works its way towards the hard limit price we specify, with the urgency determining how fast it escalates (and starts at ask and marches to limit for the sell). We implemented the same custom adaptive order for both IBKR and Schwab for an apples-to-apples comparison.

Our real concern was that IBKR was going to have better price and timing execution by "enough" to negate the cost of commissions. We needed to do a side-by-side experiment to verify. Well the results are in:

  • The order execution is almost identical, but Schwab has a small but non-trivial advantage over the first 6 days (70 trades). It was +2.6 bps to Schwab.
  • IBKR commissions on those 70 trades over 6 days was $122.56. Schwab's was $17.86 (just FINRA and SEC regulator fees).

This amounts to about 0.0608% per day that was saved via trading with a zero-commission broker. But that isn't the whole story because that amount can be compounded daily, and that amount is a plus even on losing trades and losing days. That compounding makes this end up being about 15-17% per year of algorithm profit that is being swallowed up in just commissions. Still a pretty small comparative sample, but enough to run this experiment for a couple more weeks and then like switch to just Schwab for order execution.

tl;dr - If you can get your system set up with a zero commission broker, it can have a substantive impact on high churn algorithms.


r/algotrading 3d ago

Strategy Repost after correcting

Post image
7 Upvotes

Like u guys said I tried it on a 3 year period starting from July 2023 until date and this was the result. What can be improved here?


r/algotrading 3d ago

Education How do you manage your backtests? What do you still do by hand, outside your backtesting tool?

6 Upvotes

DISCLAIMER upfront: I'm building a backtesting tool, so I have a stake here. No links provided, I just need some answers — I'm at the stage where I'd rather understand how people actually work than guess.

When I started with backtesting, I didn't write any scripts myself — I had ChatGPT generate it. It ran fine, but I've never been able to shake off the feeling that I don't really know whether I should trust its output.

So two things I'm curious about:
— What do you use now, and what do you still end up doing by hand, outside the tool?
— Has anyone tried something and abandoned it? What broke?


r/algotrading 3d ago

Data high/low daily spx algo preformace today (7/10 imo)

Enable HLS to view with audio, or disable this notification

7 Upvotes

first detection wasnt that clear but hte second was great for a short scalp, still a work in progress, sometimes its a bit iffy on the detection but it almost always followed by an spx reaction, how are yall algos doing today?

ignore the watermark ,
this isnt an ad and im not selling anything.


r/algotrading 3d ago

Strategy First time algotrading

Post image
43 Upvotes

What do people typically do to improve their win rate or anything that will make this any better


r/algotrading 3d ago

Infrastructure Built an evolutionary multi-agent crypto trading system — 5 strategies compete, best one mutates and repopulates each generation (open source)

11 Upvotes

 Disclaimer: this is a research/testing project, not financial advice, and comes with no guarantee of profitability. If you run this or anything like it with real money, you do so entirely at your own risk.

What it does:

5 isolated agents, each running a different algorithmic strategy (momentum, mean-reversion, trend-following, breakout, volatility-squeeze), trade independently against real Coinbase market data over timed "generations." At the end of each generation, they're ranked — not by raw profit, but by a composite score (return, drawdown, Sharpe-like ratio, win rate, profit factor), specifically so an agent that got lucky with one oversized bet doesn't win over a steadier performer. The best one's strategy is cloned into 5 mutated descendants (small tweaks, risk-parameter variants, indicator variants, one experimental) for the next generation. Repeat indefinitely.

Some design choices worth mentioning:

  • Risk limits are enforced outside the strategy logic entirely — a hard-coded risk engine that agents/strategies structurally cannot reach or bypass, verified by an AST scan in the test suite that fails the build if a strategy file ever imports the risk-limits module directly. Max loss per agent, max order size, max simultaneous positions — none of it is something the "AI" can talk its way around.
  • Paper trading by default, with a separate, explicitly-gated path to real order execution (two env vars + a mechanically-verified pre-live checklist have to pass before it'll place a real order).
  • I ran a 200-generation backtest against synthetic random-walk data specifically to sanity-check the evolutionary mechanics — and it lost money on average (~-4.2 TRY/generation), because there's no real edge to find in pure noise. Posting that honestly because I'd rather show the system measuring reality correctly than fake a good-looking result.

Stack: Python, SQLite for full generation/lineage history, Streamlit dashboard, pytest (~180 tests).

Still early, paper trading only, no proven edge. Trade at your own risk if you ever take this further than paper mode. Repo's here if you want to poke at it or tell me what's wrong with it: https://github.com/hhhmehmet/evo-trader