Академический Документы
Профессиональный Документы
Культура Документы
2019, 12:49
A Quant’s Approach to
Building Trading Strategies:
Part Three
BY:RAQUEL SAPNU INDUSTRY TRENDS FEB 24 2016 Tags: Quantitative analysis
You can read the first part of the interview here and the second part of
the interview here. Readers’ questions have been lightly edited for
clarity.
1. How do you monitor and manage your model once live? What
additional checks and procedures do you use?
https://blog.quandl.com/interview-with-a-quant-part-three Strona 2 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
(If you could somehow calibrate your circuit breaker to only stop you out
of catastrophes, you’d e!ectively have built a “max-deviation-indicator.”
As with perpetual motion machines, this is a reductio ad absurdum
argument.)
Note that I’m talking about classic quant arb portfolios here, not
electronic execution or HFT. In the latter cases, I can totally see why
you’d want multiple fail-safes and circuit breakers — those books can get
away from you really fast. But that’s not my area of expertise.
Within my area, I’ve observed a few patterns in models that break. For
starters, they rarely blow up instantly. Instead, either the opportunity
just gradually disappears (arbitraged away by copycats), or the spread
slowly and imperceptibly drifts further and further away from fair value
and never comes back (regime change).
So the paradoxical conclusion is that the faster a model loses money, the
more likely it is to be still valid.
https://blog.quandl.com/interview-with-a-quant-part-three Strona 3 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
This was the single most commonly asked question. And I’m afraid I’ll
have to disappoint everyone: I don’t know the answer. I wish I did!
For me, I use a variety of rules of thumb. Statistical tests to make sure
the meta-characteristics of the model remain intact. Anecdotal evidence
of capital entering or leaving the market. Other people’s positions and
pain. Price action: is it nervous and choppy, or dull and arbed out? And
so on.
Absolutely, and this is a great point. Models do come back from the dead.
US T-note futures versus cash is a classic example: it cycled between
“easy money”, “completely arbitraged out”, and “blowup central” three
times in my trading career. Same science in each case; all that changed
was the market’s risk appetite. So I never say goodbye to a model forever;
I have a huge back catalogue of ideas whose time may come again.
https://blog.quandl.com/interview-with-a-quant-part-three Strona 4 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
I’m aware of the literature on this (Kelly criterion and its descendants),
and by and large my positions are consistent with those rules. But I use
them as a sanity check, not as a primary determinant of positions.
You have to keep evolving with the markets. No single system or strategy
works forever.
8. I observe that you have already used Matlab, Python and Excel
(and presumably use C#/C++/Java) for production. Isn’t the
process of shifting between di!erent languages (like Matlab,
Python, C#/C++/Java 4) cumbersome?
It’s not that cumbersome. I typically find that the most tedious part is
making sure the data "ows consistently and smoothly between di!erent
https://blog.quandl.com/interview-with-a-quant-part-three Strona 5 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
These days, you’re right, there’s not much you cannot do in Python. And
indeed I find myself using Python more and more. But that was not
always the case; the plethora of open-source financial libraries in Python
is a relatively recent phenomenon.
I totally agree. Excel is fragile in many ways. It’s easy to make operational
mistakes, it’s impossible to audit, it’s not very performant, it hangs at the
most inconvenient times. So you have to be very careful in how and
where you use Excel. That said, I do find the benefits outweigh the many
costs.
Depends on the strategy. I’d say the median is 4-5 weeks for the first cut,
and maybe another 2-3 weeks for fixes and tweaks. Some strategies are
simpler and can be brought live in a matter of days. On the other hand, I
remember one particular strategy that took several months to
instantiate. It turned out to be super profitable so in that case it was
https://blog.quandl.com/interview-with-a-quant-part-three Strona 6 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
worth it, but in general I’d want to move a lot faster than that.
Make no mistake: once you’ve found a new source of alpha, the clock is
ticking. You’re in a race to extract as much PL as possible before the
opportunity fades away.
On the other hand, if I keep the parameters the same, then instead of
picking up, say, a six-month trend, I’m picking up a six-business day
trend. But the sweet spot for trend following most assets tends to be a
fair bit slower than that so it’s unlikely to look as good. Also my turnover
will be a lot higher, but then you’d expect that. To put it another way, I’m
not sure all aspects of market behaviour are “fractal” such that I can just
apply exactly the same model to di!erent time scales.
Are markets fractal? Great question and one I’ve spent many evenings
debating.
https://blog.quandl.com/interview-with-a-quant-part-three Strona 7 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
So I’m actually very cautious about which strategies I’d do this kind of
time-shifting with.
Here’s a toy strategy where time-shifting can work. Take two futures
strips in the same space — maybe winter and spring wheat. Look for
cases when one is backwardated and the other is in contango. Buy front
low, sell back high, sell front high, buy back low. A totally simple, almost
“dumb” strategy, but for many futures pairs it used to work well.
This is a great case for changing time scales. This strategy should work
whether you sample/rebalance weekly, or monthly, or quarterly —
because the decision variables are pure state, no path. We’re not looking
at price histories; nor are we looking at instruments with a time
component (bonds which accrue, or options which decay, or random
walks with a drift). So, given that the strategy is really clean, we can get
away with this kind of robustness test.
(Caveat: bid-ask is the one complicating factor here — your chosen time-
scale needs to be big enough to allow for price action that overcomes
friction. Bid-ask is the bane of quants everywhere.)
But I would never apply this same test to, say, a trend-following strategy.
That would raise all sorts of philosophical questions. What does it mean
for a strategy to have a “sweet spot” at say nine days, or 200 days, or
whenever? By optimizing for that sweet spot, are you curve-fitting? Or
SHARE
https://blog.quandl.com/interview-with-a-quant-part-three Strona 8 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
SHARE
does the fact that almost everyone uses 9d and 200d create a self-
fulfilling prophecy, and so those numbers represent something
structural about the market? I’ve heard convincing arguments both
ways. What if you sampled your data at interval X, and then did 9X and
200X moving averages — would that work? Fun philosophical questions.
I’m not sure of the answers myself.
13. Could you give more details on the use of Monte Carlo in
parameters initialization?
For most optimizations, I need to have a vector of initial guesses for the
parameters – the “starting point” for my n-dimensional gradient
descent. The problem is, non-linear systems tend to have local minima
which it’s easy to get sucked into. You can use random jumps (“simulated
annealing”) to escape these, but I find that a more robust method is to
re-run the optimization many times but with di!erent starting points. I
use Monte Carlo sampling to generate these starting points: basically,
pick random values for each parameter (consistent with that parameter’s
distribution characteristics).
14. How do you scale your trading strategy? How much gain per
transaction would be considered a good model? And on what time
scale is it trading? What range of time scales are used in your
industry? How much money can there be poured into a successful
scheme, is this limited by how much money your fund has
available or are there typically limits on the trading scheme
itself?
I have a few rules that I try to follow.
https://blog.quandl.com/interview-with-a-quant-part-three Strona 9 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
Incidentally, optimal scale changes over time. I know some of the LTCM
folks, and they used to make full points of arbitrage profit on Treasuries
over a span of weeks. A decade later, that same trade would make mere
ticks: a 30-fold compression in opportunity. You have to be aware of and
adapt to structural changes in the market, as knowledge di!uses.
https://blog.quandl.com/interview-with-a-quant-part-three Strona 10 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
Also, we use similar “"avors” of models but they’re not exactly the same.
He does smaller trades for quicker opportunities with tighter stops. And
he’s willing to recalibrate “fair value” much more rapidly than me. In
some specific areas, he’s almost a market-maker (that’s how he defrays
bid-ask). I’m not; I’m definitely a price taker.
16. Do you have advice for someone who just started as a quant at
a systematic hedge fund? How do I become really good at this?
What di!erentiates the ones who succeed from those who do not?
In a nutshell: intellectual discipline. By which I mean a combination of
procedural rigor, lack of self-deception, and humility in the face of data.
Quants tend to get enamoured of their models and stick to them at all
costs. The intellectual satisfaction of a beautiful model or technology is
seductive. It’s even worse if the model is successful: in addition to
emotional attachment, you have to contend with hubris. Then one day it
all comes crashing down around you.
https://blog.quandl.com/interview-with-a-quant-part-three Strona 11 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
The reason I’ve been successful in this industry over decades is that I
have a keen sense of my own ignorance, and I’m not afraid of appearing a
fool. I ask dumb questions, I question everything, I constantly re-
examine my own assumptions. This helps me re-invent myself as the
market changes.
SHARE
RELATED ARTICLES
https://blog.quandl.com/interview-with-a-quant-part-three Strona 12 z 13
A Quant’s Approach to Building Trading Strategies: Part Three | 29.12.2019, 12:49
https://blog.quandl.com/interview-with-a-quant-part-three Strona 13 z 13