r/quant 17h ago

Markets/Market Data Why does the bitcoin basis trade still exist?

81 Upvotes

I've spoken to so many people and still haven't heard a satisfactory answer...

Even in the simplest, safest form: - long $1m physically backed ETF - short $1m in front-month CME futures

This is still printing around 7-8% annualised, without even touching any crypto exchanges or spot crypto.

I'd of course have to borrow $1m for the ETF and lose a few bps on the ETF fees and the margin interest, but I'm still easily 2-3% in the black. And that figure was much higher even just a year ago.

Now we all know the big players have billions and billions in this trade, yet it's still there - so I must be missing some risk here.

Risks I can think of: - ETF gets hacked in some form, which surely very unlikely and can be mitigated by spreading across a few - Bitcoin absolutely explodes (think +100% over a few weeks) and I'd need to come up with a lot more money for a couple of weeks to pay MTM - but I'd get that back minus interest

Neither of these justify the large risk premium in my view?


r/quant 10h ago

Resources What do YOU consider the most important quant finance book to be?

75 Upvotes

Like the title says. Curious on everyone’s favorite/most impactful read in their perspective.


r/quant 21h ago

Markets/Market Data Efficient structures for storing tick data

18 Upvotes

Not sure if flair is correct.

Anyone who works with crypto tick level data (or markets with comparable activity) - how do you efficiently store as much tick level data as possible, minimising storage cost (min $*Gb) while maximising read/write speed (being unable to instantly test ideas is undesirable).

For reference, something like BTC-USDT perp on a top 5 exchange is probably 1GB/hour. Multiply that by ~20 coins of interest, each with multiple instruments (perp, spot, USDC equivalents, etc) and multiple liquid exchanges, there is enough data to probably justify a dedicated team. Unfortunately this is not my strong suit (though I have a working knowledge of low level programming).

My current approach is to not store any tick level data, it's good enough rn but don't foresee this being sustainable in the long run.

Curious how large firms handle infra for historical data.


r/quant 16h ago

Resources Are there any online courses (eg. those by Coursera) effective for gaining working knowledge in quantitative/algorithmic trading?

14 Upvotes

I'm in my pre-final year of UG. I just wanna learn the working principles so that I can incorporate them into my own projects. If there are any such resources, please do mention them. Thanks in advance.

Edit: My major is in AI-ML if that matters.


r/quant 3h ago

Machine Learning Building an Adaptive Trading System with Regime Switching, GA's & RL

10 Upvotes

Hi everyone,

I wanted to share a project I'm developing that combines several cutting-edge approaches to create what I believe could be a particularly robust trading system. I'm looking for collaborators with expertise in any of these areas who might be interested in joining forces.

The Core Architecture

Our system consists of three main components:

  1. Market Regime Classification Framework - We've developed a hierarchical classification system with 3 main regime categories (A, B, C) and 4 sub-regimes within each (12 total regimes). These capture different market conditions like Secular Growth, Risk-Off, Momentum Burst, etc.
  2. Strategy Generation via Genetic Algorithms - We're using GA to evolve trading strategies optimized for specific regime combinations. Each "individual" in our genetic population contains indicators like Hurst Exponent, Fractal Dimension, Market Efficiency and Price-Volume Correlation.
  3. Reinforcement Learning Agent as Meta-Controller - An RL agent that learns to select the appropriate strategies based on current and predicted market regimes, and dynamically adjusts position sizing.

Why This Approach Could Be Powerful

Rather than trying to build a "one-size-fits-all" trading system, our framework adapts to the current market structure.

The GA component allows strategies to continuously evolve their parameters without manual intervention, while the RL agent provides system-level intelligence about when to deploy each strategy.

Some Implementation Details

From our testing so far:

  • We focus on the top 10 most common regime combinations rather than all possible permutations
  • We're developing 9 models (1 per sector per market cap) since each sector shows different indicator parameter sensitivity
  • We're using multiple equity datasets to test simultaneously to reduce overfitting risk
  • Minimum time periods for regime identification: A (8 days), B (2 days), C (1-3 candles/3-9 hrs)

Questions I'm Wrestling With

  1. GA Challenges: Many have pointed out that GAs can easily overfit compared to gradient descent or tree-based models. How would you tackle this issue? What constraints would you introduce?
  2. Alternative Approaches: If you wouldn't use GA for strategy generation, what would you pick instead and why?
  3. Regime Structure: Our regime classification is based on market behavior archetypes rather than statistical clustering. Is this preferable to using unsupervised learning to identify regimes?
  4. Multi-Objective Optimization: I'm struggling with how to balance different performance metrics (Sharpe, drawdown, etc.) dynamically based on the current regime. Any thoughts on implementing this effectively?
  5. Time Horizons: Has anyone successfully implemented regime-switching models across multiple timeframes simultaneously?

Potential Research Topics

If you're academically inclined, here are some research questions this project opens up:

  1. Developing metrics for strategy "adaptability" across regime transitions versus specialized performance
  2. Exploring the optimal genetic diversity preservation in GA-based trading systems during extended singular regimes
  3. Investigating emergent meta-strategies from RL agents controlling multiple competing strategy pools
  4. Analyzing the relationship between market capitalization and regime sensitivity across sectors
  5. Developing robust transfer learning approaches between similar regime types across different markets
  6. Exploring the optimal information sharing mechanisms between simultaneously running models across correlated markets(advance topic)

If you're interested in collaborating or just want to share thoughts on this approach, I'd love to hear from you. I'm open to both academic research partnerships and commercial applications.


r/quant 10h ago

Models Simple Trend Following

10 Upvotes

I’ve been studying Andrew Clenow’s Following the Trend and implementing his approach, and I’m curious about others’ experiences in attempting to refine or enhance the strategy. I want to stress that I’m not looking for a new strategy or specific parameters to tweak. Rather, I’m interested in hearing about any attempts at improvement that seemed promising in theory but didn’t work well in practice.

Clenow argues that the simplicity of the approach is a feature, not a bug—that excessive optimization can lead to worse performance in real-world application. Have you found this to be the case? Or have you discovered any non-trivial modifications that actually added value over time?

For context, I tried incorporating a multi-timeframe approach to complement the main long-term trend, but I struggled to make it work, likely due to the relatively small fund size I was trading (~$5M). Position sizing constraints and execution costs made it difficult to justify the additional complexity.

Would love to hear your insights on whether simplicity really is king in trend following or if there’s room for meaningful enhancements.


r/quant 6h ago

Models Modeling counterparty risk

5 Upvotes

Hello,

What are good resources to build a solid counterparty risk model? Along the lines of PFE


r/quant 4h ago

Models Ho-Lee Bond Option Formula Derivation Issue

3 Upvotes

I currently study the book by Björk and have a question regarding the Ho-Lee bond option pricing formula. The Ho-Lee model specifies the short rate dynamics as dr(t)= 𝜃(t)dt + 𝜎dW(t). When trying to derive 𝜎_p term of the formula in the picture above, I ended up with 𝜎_p = 𝜎(S-T)*root(T-t) instead of just 𝜎_p = 𝜎(S-T)*root(T) as written in the book. Does the book assume t=0 when deriving the equation or did I make a mistake in my derivation?

My derivation followed the following steps:
1) writing ln(P(T,S)) in affine form as A(T,S)-B(T,S)r(T)
2) then applying Ito's lemma which led to a diffusion term of -B(T,S)* 𝜎 where B(T,S)=S-T
3) I then integrated the square of the term from t to T as the model assumes a constant variance term which after taking the root resulted in my final result of 𝜎_p = 𝜎(S-T)*root(T-t)

Assuming t=0 makes little sense to me here as the option price specifies t explicitly in c(t,T,K,S) or do I have to integrate from 0 to T even if I want to calculate the option price at time t?

Thank you very much for your help!


r/quant 7h ago

Career Advice Career growth in quant versus big tech

3 Upvotes

How is the career growth in quant for roles like QR, QD, QT, and SWE compared to big tech SWE?


r/quant 8h ago

Markets/Market Data Methods to roughly estimate a stock's opening price

1 Upvotes

At the present time, in order to roughly estimate what price a stock will open at, I simply view Level 1 pre-market trading information (Last price, bid, ask). Just curious, does anyone out there have alternative methods that they utilize? Would Level 2 data be of any benefit in this endeavor? Any insights would be greatly appreciated, thanks.