Project demo

I built a tiny stock market — and a lie detector for trading strategies.

A simulated market where the price isn't set by anyone — it emerges from thousands of trades. Then I used it to ask a simple question, honestly: can you actually beat the market? Play with the market below, then see what I found.

Try the market ↓

1. Watch a market come alive

A real price isn't decided by one person. It's the result of a crowd buying and selling at once. Below is a miniature version. Each dot is a trader buying, selling, and waiting. The line at the top is the price — notice that no one sets it; it just falls out of everyone's trades. Press play and drag the sliders.

Price
Mood
Choppiness (volatility)

A simplified illustration that runs entirely in your browser. The real project simulates a full order book with many trader types — but the idea is exactly this: price is an emergent crowd phenomenon.

2. The honest experiment: can you beat the market?

It's tempting to believe you can find a pattern that prints money. So I tested eight different kinds of strategies on real market data — trend-following, “buy the dip,” momentum, calendar effects, and more.

The catch: if you try enough random strategies, one will look great by pure luck. To avoid fooling myself, every strategy had to pass a strict statistical “lie detector” (it corrects for how many things you tried) and still win after the real cost of trading.

8 strategy types tested
0 that honestly beat the market

That's not a failure — it's the truth. Liquid markets are efficient: the easy patterns are already traded away. Most people who think they have an edge simply haven't tested it honestly. Building the test that says “no” is the hard, valuable part.

3. The one real pattern: how wild tomorrow will be

You can't reliably predict which way the price goes. But there is something you can predict: volatility — how much prices swing around. Calm days tend to follow calm days; stormy days cluster together. (You can even see it in the demo above: turn up “Chaotic” and the swings stay big for a while.)

My forecast of this “choppiness” matched the industry-standard models on real data, out-of-sample, across both stocks and crypto. You don't get rich betting on direction — but forecasting risk is exactly what banks and funds use to size positions and manage danger. So the project found a real, useful signal — just not the get-rich one.

4. Why this was worth building

The valuable part was never striking gold. It was building a research system honest enough to tell me “no” — with safeguards against the classic ways people fool themselves (curve-fitting, ignoring costs, peeking at the answer). Every result is logged in a tamper-evident record so nothing can be quietly re-spun.

  • 🧱 A market simulator: order book, many trader types, emergent prices.
  • 🔬 A validation pipeline with proper statistics and leakage controls.
  • 🧾 An honest verdict: no easy edge, but volatility is forecastable.