/r/algotrading
55 subscribers
1.17K photos
27 videos
5.36K links
/r/algotrading; @r_channels; @reddit2telegram
Download Telegram
A List Containing Symbols, Yahoo Finance Tickers, Company Name and Exchange Name of Nearly Every Stock Across Several Major Exchanges Across The Globe.

[](https://www.reddit.com/r/algotrading/?f=flair_name%3A%22Data%22)[https://github.com/Tejashv-dev/AllStocks](https://github.com/Tejashv-dev/AllStocks)

This might not be useful for most people here but maybe some day other dev - who does not want to get into the rabbithole of scraping tradingview and yahoo finance and downloading several master files from exchanges - might find this useful. Actually took many hours to finally make because yahoo finance ticker conventions are a menace and then different classes of same stock exist across several exchanges. (still not perfect tho)

https://redd.it/1v1lekg
@r_algotrading
What do you wish you knew before you started automating your trading?

Ben looking into this recently after spending most of my time trading manually. The coding side seems manageable but the more I read, the more I realize theres a lot of things that can go wrong with backtesting, optimization, execution, etc.

For the experienced out there, what was the biggest lesson you learned that you wish someone had told you when you were starting out?

https://redd.it/1v1n748
@r_algotrading
Is there anyone in the green with 3+ years of trading?

The more I get into trading, the less I can believe it

https://redd.it/1v1pa4u
@r_algotrading
What is your workflow on researching an edge?

For the past year and a half I’ve been always following the same process:

1) having an idea
2) researching for papers developing the core idea and testing it
3) coding it simply in Multicharts (to see if the equity curve could be interesting)
4) testing it deeply and developing a strategy in QuantConnect

I found out that this process is effective for me but it could become better.

What is your workflow on testing, developing and implementing?

Also I’m trying to found a method to mass test strategies so if any of you know let me know

https://redd.it/1v1sz7l
@r_algotrading
Need more advanced books

I've been doing quantitative strategy development for some time now and Ive reached the point where Im struggling to find books that actually teach me something new. I already have a solid understanding of the usual topics like IS/Validation/OOS splits WFO, cross-validation, permutation tests, bootstrapping, entropy, regime detection, and the other standard robustness techniques. I recently read Testing and Tuning Market Trading Systems by Timothy Masters but it covered concepts I was already familiar with.

Im looking for books that are genuinely advanced and make you think differently. Perhaps graduate level or even post graduate books on statistics, machine learning, optimization, information theory, econometrics, or anything else that completely changed the way you approach research and model development. And of course it would be great if the book wasnt 10 years old. Need relevance.

https://redd.it/1v2ljlw
@r_algotrading
I open-sourced my Polymarket market-making bot (MIT)

A few weeks ago I posted the retro of this bot here, then the post-mortem on why the forced directional residual lost money (adverse selection, mostly - stale quotes getting picked off). A few of you asked for the code. I'll include it as a link in the comments.

https://redd.it/1v2oyv1
@r_algotrading
Backtesting four investing philosophies with point-in-time LLM-graded fundamentals (no lookahead, calibrated)

I ran an experiment on whether qualitative fundamentals carry any signal once you control the usual ways a backtest lies to you.

Setup. About 250 S&P 500 companies graded from their 10-K filings on moat, market position, leadership and capital allocation. Grading is point-in-time, the grader only sees the filing for that vintage, across 2014, 2017 and 2020. Index membership reconstructed as-of the vintage so there is no survivorship. Cross-validation folds grouped by ticker so the same company cannot sit on both sides. The predictor is a predictive database, so there is no training step, the calibrated probability comes back from a query with a per-feature contribution breakdown.

Results. Exact-outcome accuracy is about 35% against a 27% base rate, which is unimpressive on its own. But the ranking has real spread: the top-20 fund returned 20.6%/yr against the market's 7.9% and the bottom-20 lost money. That is the actual point, calibrated ordering beats point accuracy for anything you would size positions on. Brier 0.181.

One result I did not expect: using all 16 features made it worse, information gain dropped from 0.107 with 6 decorrelated features to 0.023 with everything. More features added noise, not redundancy.

By philosophy, growth won the top-20 sprint at 31%/yr and it was entirely the semiconductor cluster. Value hit 24.8% and decayed the fastest. Quality mostly avoided disasters. The composite posted a lower 19.5% but barely decayed as you scale to 100 names, minus 1.7 points versus growth's minus 9.6.

Limits I will state before you do: small sample, 12-year horizon, no transaction costs, and the winning sector is visible in the training outcomes, so this is what would have worked and not what you could have known in 2015. The LLM grades also risk a halo from firms that were already winning, though the headline model leans on the less-haloed features and passes a per-vintage drift check.

Playable, no signup: https://demos.aito.ai/equity 

Methodology writeup: https://aito.ai/blog/value-quality-or-growth-who-was-right

Happy to get into the fold construction or where you think the grading still leaks.

https://redd.it/1v2lwjg
@r_algotrading
Weekly Discussion Thread - July 21, 2026

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.

https://redd.it/1v2e0cy
@r_algotrading
Beating the Market with RSI and SPY Rotation

Hello again everyone, I want to share another strategy that I've been working on that I thought I would share with you folks to hear your thoughts.

The whole strategy is based on using the RSI indicator but instead of using it on the close, using it on the EMA 20 (RSI-EMA). I find that it is much smoother and gives stronger signals across timeframes vs. traditional RSI. A few backtests that I've done also find that the RSI-EMA is a fairly strong modification that produces more consistent wins and better results.

I of course wanted to turn this into a trading systems and had played around with various formulas, and entries and exits but believe that I finally found a system that may work well.

The set up is as follows. I use a universe of the top 20 companies in the S&P 500 by market cap (data goes back to 1989 and can be found here; my own backtest is 2010 to present). The tickers used for a current year are based on the top 20 companies from the previous year to avoid any lookahead/survivorship bias.

Within a given year, when an equity's RSI-EMA in the top 20 crosses over 30, I buy that stock. If there are multiple crossovers, I buy the one with the lowest RSI (but over 30 as it's crossing over). When there isn't an equity crossing over, capital is shifted into SPY. Exits occur after 10 trading days with all entries/exits happening at the next open. This system also uses 100% of the capital in each trade.

That's it!

With respect to exits, I tested using an ATR based exit (1.0 in either direction) and an RSI-EMA based exit (when it crosses above 70 or crosses back below 30). I also included a slippage penalty of 5 bps (0.05%).

Here are the results based on the various exits (initial capital $100,000; backtest starts in 2010):

Yearly results:

|Year|SPY B&H|1. Time (10d)|2. RSI Target/Redrop|3. ATR (1.0x)|
|:-|:-|:-|:-|:-|
|2010|15.06%|22.85%|17.38%|9.70%|
|2011|1.89%|4.07%|3.08%|\-8.03%|
|2012|15.99%|31.31%|12.03%|2.11%|
|2013|32.31%|\-0.49%|0.65%|16.93%|
|2014|13.46%|34.68%|18.43%|\-8.65%|
|2015|1.25%|\-12.50%|\-12.84%|\-17.62%|
|2016|12.00%|17.88%|13.21%|5.88%|
|2017|21.70%|21.34%|28.49%|9.28%|
|2018|\-4.56%|24.74%|\-3.02%|\-32.06%|
|2019|31.22%|37.67%|18.69%|29.36%|
|2020|18.37%|16.11%|22.22%|\-3.15%|
|2021|28.75%|10.55%|\-19.53%|2.38%|
|2022|\-18.17%|\-31.10%|\-18.92%|\-46.60%|
|2023|26.19%|27.41%|24.82%|\-7.01%|
|2024|24.89%|63.29%|86.76%|14.41%|
|2025|17.72%|20.98%|30.48%|\-20.81%|
|2026|10.16%|45.43%|9.36%|126.31%|
|---|---|---|---|---|
|Avg Return|15.13%|19.66%|15.96%|4.28%|
|Std Dev|12.60%|21.95%|24.52%|37.38%|
|Sharpe|1.20|0.90|0.65|0.11|

|Strategy|Final|Net Profit|Return|Trades|Win Rate|Avg Ret|Avg Hold|Worst Trade|
|:-|:-|:-|:-|:-|:-|:-|:-|:-|
|1. Fixed 10-Day Time Limit|$1,565,613|$1,465,613|1465.61%|231|58.01%|1.00%|10.0d|\-26.72%|
|2. RSI > 70 Target (Redrop < 30 Exit)|$625,288|$525,288|525.29%|245|61.22%|0.67%|10.2d|\-22.03%|
|3. 1.0x ATR Stop (Pure Intraday)|$93,071|\-$6,929|\-6.93%|37|2.70%|1.47%|105.7d|\-5.76%|

What if we experiment with the different number of holdings days? We see that generally 12 - 16 days is the ideal hold time with returns being lower on either side of that range. To minimize slippage and the number of trades, I would likely pivot to 15 trading days instead of 10.

|Hold Days|Trades|Win Rate|CAGR|Final
Equity|
|:-|:-|:-|:-|:-|
||||||
|5|326|54.3%|8.79%|$401,551|
|6|306|54.6%|8.17%|$365,193|
|7|288|53.8%|9.72%|$461,591|
|8|262|55.3%|13.95%|$862,307|
|9|243|54.3%|13.18%|$770,630|
|10|231|58.0%|18.15%|$1,565,613|
|11|220|54.1%|13.75%|$837,275|
|12|206|57.3%|18.59%|$1,664,395|
|13|197|57.4%|17.48%|$1,424,912|
|14|189|58.7%|20.72%|$2,231,678|
|15|183|59.0%|23.10%|$3,082,154|
|16|177|55.9%|19.40%|$1,862,937|
|17|170|54.7%|12.81%|$730,494|
|18|162|54.9%|11.27%|$582,300|
|19|156|57.1%|11.47%|$599,320|
|20|147|58.5%|8.87%|$406,290|

And that's that! I would love to hear any feedback including criticisms, general thoughts and suggestions to improve.

https://redd.it/1v3fmef
@r_algotrading
Is there a tool that connects prediction markets to your stock portfolio?

The more I think about prediction markets, the more useful they seem as real-time probability engines for events such as elections, wars, regulation, tariffs, and broader geopolitical risks.

Is there already a tool where you can upload your stock portfolio and automatically identify relevant Polymarket or Kalshi markets?

For example:

Which prediction markets are most relevant to my holdings?
Are current probabilities creating headwinds or tailwinds for my portfolio?
Which stocks have the highest exposure to a specific event?
How would my portfolio react if the market-implied probability changed significantly?

Essentially, I am looking for a portfolio risk dashboard powered by prediction-market data.

Does anything like this already exist? And would you actually use it?

EDIT - Found Oracle Markts here via my ChatGPT "research" and user comment: https://oraclemarkets.io/portfolio

https://redd.it/1v3bdfi
@r_algotrading