As an algorithmic trader, I spend most of my time looking for quantifiable edges in the market. This time (a bit for fun) I wanted to check classic candlestick patterns that manual traders use—things like the "Morning star" or "Three White Soldiers." Is there any real, statistical "alpha" to be found in them?
To find out, I built a tool to rigorously backtest these patterns at scale. This project is a high-performance analysis engine that searches for these patterns across years of 1-hour Binance Futures data and measures their historical profitability.
What made this project especially interesting for me is that it was my first real project in Rust. I was able to build it much faster than I ever expected, largely because I used Cursor. Having an AI assistant that could explain Rust's concepts directly in my IDE was a complete game-changer. It felt like pair programming and dramatically shortened the learning curve.
The link goes to a static HTML report generated by the tool, summarizing the performance of various patterns.
A few technical details:
* Tech Stack: It's built in Rust using Tokio for parallelism when analyzing symbols, and serde/csv for data handling. The frontend is plain HTML/JS with static Tailwind CSS and ECharts.js for the interactive charts.
* The "How": The core challenge is comparing patterns that occur at wildly different price levels and volatility. To solve this, the matching logic uses Z-Score Normalization on rolling windows of data. This allows for a true "shape-based" comparison. It then uses a KNN-style search with a binary heap to efficiently find the top N closest matches without having to store them all in memory.
* The Data: ~8 MLN 1-hour candles from all Binance Futures symbols (~490) including delisted ones to avoid survivorship bias.
Of course, this is not financial advice, and past performance is not an indicator of future results. The goal was to explore a specific dataset for historical statistical edges.
I'd love to hear your thoughts, critiques, or any questions you might have. Happy to discuss the technical implementation or the results.
piotrwilczek•5h ago
As an algorithmic trader, I spend most of my time looking for quantifiable edges in the market. This time (a bit for fun) I wanted to check classic candlestick patterns that manual traders use—things like the "Morning star" or "Three White Soldiers." Is there any real, statistical "alpha" to be found in them?
To find out, I built a tool to rigorously backtest these patterns at scale. This project is a high-performance analysis engine that searches for these patterns across years of 1-hour Binance Futures data and measures their historical profitability.
What made this project especially interesting for me is that it was my first real project in Rust. I was able to build it much faster than I ever expected, largely because I used Cursor. Having an AI assistant that could explain Rust's concepts directly in my IDE was a complete game-changer. It felt like pair programming and dramatically shortened the learning curve.
The link goes to a static HTML report generated by the tool, summarizing the performance of various patterns.
A few technical details:
* Tech Stack: It's built in Rust using Tokio for parallelism when analyzing symbols, and serde/csv for data handling. The frontend is plain HTML/JS with static Tailwind CSS and ECharts.js for the interactive charts.
* The "How": The core challenge is comparing patterns that occur at wildly different price levels and volatility. To solve this, the matching logic uses Z-Score Normalization on rolling windows of data. This allows for a true "shape-based" comparison. It then uses a KNN-style search with a binary heap to efficiently find the top N closest matches without having to store them all in memory.
* The Data: ~8 MLN 1-hour candles from all Binance Futures symbols (~490) including delisted ones to avoid survivorship bias.
Of course, this is not financial advice, and past performance is not an indicator of future results. The goal was to explore a specific dataset for historical statistical edges.
I'd love to hear your thoughts, critiques, or any questions you might have. Happy to discuss the technical implementation or the results.