The Butcher and the Beaver
This blog covers:
coin-toss hedging discount-factor coupon-bond zero-coupon-bond yield bond-market treasury banking stock-market fed economists monte-carlo Black-Scholes binomial-lattice option-pricing options winning adaptability evolution Keynesian-economics Krugman productivity funding America Heine mathematics physics economics Dirac default-probability bonds investing money trading-strategy book-finance Derman math games probability gambling entertainmentRecent posts
This blog has moved here:
http://www.exstrom.com/blog/snark/
Please update your link/RSS.
We have a coin toss app for the Chrome browser. If you buy the app in the chrome web store you get 98 additional coins, for a total of 103 coins, and advertisements are also eliminated. The coin images are courtesy of the U.S. Mint. The price is $29.95 (with 25% going to one of two Colorado wolf sanctuaries), but for today it's free.
The coin tosser can be useful for games, for helping you make decisions when you're not sure, for entertainment, and for generating binary (2 symbol) data.
The coin images are all United States coins, courtesy of the U.S. Mint. Some of the coins are beautiful and educational, portraying historical events, people, and places. For example, one coin honors the heart surgeon Dr. Michael E. DeBakey with a beautiful image of the heart. The Hawaiian state quarter indicates it entered the union in 1959, showing the state motto: “UA MAU KE EA O KA ‘AINA I KA PONO” (The life of the land is perpetuated in righteousness).
If you buy the app you are also helping wolves. 25% of the purchase price goes to one of two wolf sanctuaries in Colorado. Mission: Wolf in southern Colorado (Westcliffe), and Wolf Sanctuary in northern Colorado (LaPorte). As our name suggests, we are fond of wolves. Mankind has been in close contact with wolves for probably at least 100 thousand years, and all dogs, which humans are so fond of, are wolf derivatives. In meeting a wolf, we touch our past.
- Richard and Stefan Hollos
Intuition says that if you play a fair game for a long time then on average you will be ahead half the time and behind half the time. Sounds reasonable doesn't it? But it couldn't be more wrong. The two most probable outcomes are that either you remain ahead or behind the whole time. Both are equally likely. Note that what I mean by a fair game is that you have an equal chance of winning and losing the same amount and the outcome of one game can in no way affect subsequent games.
So statistically if you get ahead or behind, you tend to stay there. It's not hard to show this mathematically but you can get a sense for why it's true with a simple example. Let's say the game involves tossing an unbiased coin and you win \(\$1\) on heads and lose \(\$1\) on tails. Now suppose you win on the first toss so you are up by one dollar. To go into negative territory you need to lose the next 2 games, anything else will keep you ahead. You have a \(3/4\) probability of staying ahead and only a \(1/4\) probability of falling behind in the next two games. With a larger lead the probability of falling behind becomes even less.
The probabilities can be made precise. If you play \(2n\) games, the probability that you are positive or flat for \(2k\) games is:
\begin{equation*} g_{2k}g_{2n-2k} = \frac{\binom{2k}{k}\binom{2n-2k}{n-k}}{2^{2n}} \end{equation*}
where \(g_{2k}\) and \(g_{2n-2k}\) are the probabilities of being at zero after \(2k\) and \(2n-2k\) games respectively (see Getting Back to Zero). These probabilities are symmetric about \(k=n/2\) where there is a minimum. The maximum probabilities are at \(k=0\) and \(k=n\). The probabilities for \(n=10\) are shown below.
| \(k\) | Probability |
|---|---|
| 0 | 0.176197 |
| 1 | 0.092735 |
| 2 | 0.073643 |
| 3 | 0.065460 |
| 4 | 0.061684 |
| 5 | 0.060562 |
| 6 | 0.061684 |
| 7 | 0.065460 |
| 8 | 0.073643 |
| 9 | 0.092735 |
| 10 | 0.176197 |
The \(k=0\) probability means there is a \(17.6\) percent chance that you are either behind or at zero the whole time. The \(k=10\) probability means that there is a \(17.6\) percent chance that you are either ahead or at zero the whole time. There is only a \(6\) percent probability that you spend an equal amount of time ahead and behind.
For large \(n\) the probabilities can be approximated by the continuous arcsine distribution which has probability density function:
\begin{equation*} f(x) = \frac{1}{\pi\sqrt{x(1-x)}} \end{equation*}
and the cumulative distribution:
\begin{equation*} F(x) = \frac{2}{\pi}\arcsin(\sqrt{x}) \end{equation*}
where the range of \(x\) is \(0 \leq x \leq 1\). The probability that \(k \leq xn\) is approximately equal to \(F(x)\). As the number of games goes to infinity the approximation becomes exact and is known as the Lévy arcsine law for Brownian motion.
In the previous post I showed that a return to zero is certain when playing a fair game with an unbiased coin. So if you're in the hole you would think that just holding on long enough will get you out, or at least back to zero. This may be a bit overoptimistic. What follows is a closer look at getting back to zero in the case of a fair game.
For a fair coin the first return probability generating function is \(F(z) = 1 - \sqrt{1-z^2}\). \(\quad F(1)=1\) so the first return probabilities constitute a proper probability distribution, and a return to zero at some time or another is certain. To find the mean number of tosses or games required to get back to zero, you take the derivative of \(F(z)\) and evaluate it at \(z=1\). The derivative is
\begin{equation*} \acute{F}(z) = \frac{z}{\sqrt{1-z^2}} \end{equation*}
At \(z=1\) the derivative is \(\infty\). This means that even though a return to zero is certain, you may have to wait a very long time for it to happen. To be fairly certain of getting out of the hole you will need a very large bankroll and be willing to play for a very long time.
This result can be made more precise. Using a result from the theory of random walks you can show that the probability of not getting back to zero in the first \(2N\) games is equal to the probability of getting to zero at game \(2N\). This means that if \(\bar{R}_{2N}\) is the probability that a return to zero does not occur in the first \(2N\) games then
\begin{equation*} \bar{R}_{2N} = g_{2N} = \binom{2N}{N}/2^{2N} \end{equation*}
The surprising thing is how long it takes for this probability to become negligible. After \(50\) games the probability is \(0.1123\), and after \(100\) it is still \(0.07959\). Even after \(1000\) games the probability of not returning to zero is still \(0.02522\). (Note that I have left out the derivation of this result but if you are interested, leave a comment and I will post it.)
The conclusion is that even for a fair game it may take a very long time for you to get out of a hole. On the other hand if you are ahead then it is possible that you may hold on to your lead for a very long time. Maybe this explains the apparent success of some money managers?
An interesting gambling question came up recently. Let's say you are playing a game with a probability \(p\) of winning and \(q=1-p\) of losing. After playing the game \(2n\) times, what is the probability that you are right back to where you started? In other words after \(2n\) games you have neither lost nor won any money. Assuming you always win the same amount that you lose, to get back to zero the number of games played has to be even. That's why I set the number of games at \(2n\). Let me call \(g_{2n}\) the probability of getting back to zero after \(2n\) games, then it's not hard to see that:
\begin{equation*} g_{2n} = \binom{2n}{n}p^nq^n \end{equation*}
since \(\binom{2n}{n}\) is the number of ways of playing \(2n\) games with \(n\) wins and \(n\) losses and each of the ways has a probability of \(p^nq^n\). When \(n\) is large you can use Stirling's approximation for factorials to get:
\begin{equation*} g_{2n} \approx \frac{(4pq)^n}{\sqrt{\pi n}} \end{equation*}
The interesting thing is when you look at the probability that a return to zero occurs for the first time at game \(2n\). Call this probability \(f_{2n}\). The \(g_{2n}\) and \(f_{2n}\) probabilities are related as follows
\begin{equation*} g_{2n} = f_2g_{2n-2} + f_4g_{2n-4} + f_6g_{2n-6} + \cdots + f_{2n} \end{equation*}
The right hand side of this equation sums up all the ways that a return to zero can occur at game \(2n\). You can get a first return at game \(2\) with a return \(2n-2\) games later or you can get a first return at game \(4\) with a return \(2n-4\) games later and so on. This equation lets you relate the probability generating functions for the \(g_{2n}\) and \(f_{2n}\) probabilities. The power series expansion of a probability generating function has the probabilities as coefficients of the expansion. If \(G(z)\) is the generating function for the \(g_{2n}\) probabilities then its power series expansion would look like:
\begin{equation*} G(z) = g_0 + g_2z^2 + g_4z^4 + g_6z^6 + \cdots \end{equation*}
The coefficient of \(z^{2n}\) in the expansion is \(g_{2n}\). You can write \(G(z)\) in the following compact form:
\begin{equation*} G(z) = \frac{1}{\sqrt{1-4pqz^2}} \end{equation*}
If \(F(z)\) is the generating function for the \(f_{2n}\) probabilities then the above equation for \(g_{2n}\) means that \(F(z)\) and \(G(z)\) must be related as follows
\begin{equation*} G(z) - 1 = F(z)G(z) \end{equation*}
If you solve this for \(F(z)\) you get
\begin{equation*} F(z) = 1 - \sqrt{1-4pqz^2} \end{equation*}
If you expand this in a power series you then find that \(f_{2n}\) is equal to
\begin{equation*} f_{2n} = \frac{\binom{2n}{n}}{2n-1}p^nq^n \end{equation*}
This is the probability that you get a return to zero for the first time at game \(2n\). If you sum the \(f_{2n}\) probabilities over all values of \(n\) from 1 to infinity then you get the probability that a return to zero will ever occur. You can get this sum by just evaluating \(F(1)\)
\begin{equation*} F(1) = 1 - \left|p-q\right| \end{equation*}
This equation shows that a return to zero is only certain, \(F(1)=1\), for a fair game where \(p=q=1/2\). For a game with \(p \ne q\) you have \(F(1) < 1\) and it is possible that a return to zero never occurs. The probability of no return to zero is \(\left|p-q\right|\). So if you are playing a game with the odds against you and you are in the hole but are hoping that some streak of luck will get you back to zero, it may never happen.
If you know anything about quantitative finance, then Emanuel Derman should be a familiar name. He was one of the early physicists to go to work on Wall Street, arriving at Goldman Sachs from Bell Labs in 1985. At Goldman he worked with Fischer Black and Bill Toy on what would become known as the Black–Derman–Toy interest rate model. The model is still widely used to price interest rate derivatives. In 1988 he left Goldman for Salomon Brothers where he worked on adjustable rate mortgages and bond portfolio analysis. He returned to Goldman in 1990 where he was appointed managing director in 1997 and became head of the Quantitative Risk Strategies group in 2001. He is now retired from Goldman Sachs and is currently a professor at Columbia University where he directs the Financial Engineering program. He is also a columnist for Risk magazine and a Senior Fellow of the International Association of Financial Engineers.
In his first book My Life as a Quant: Reflections on Physics and Finance, he describes his early career in physics, his move to Bell Labs and how he eventually ended up on Wall Street. The book is one of the most honest and unaffected memoirs you are likely to ever read. The book should be read by anyone contemplating a career in quantitative finance, especially anyone thinking about moving from physics to Wall Street.
In his new book Models.Behaving.Badly: Why Confusing Illusion with Reality Can Lead to Disaster, on Wall Street and in Life, he looks at how people use theories, models, and intuition to understand the world. Theories are an attempt to formalize the fundamental principles by which the world operates. Once verified, they can be taken as true descriptions of reality. A model on the other hand is just an analogy. It describes what something is like, not what it actually is. The concept of intuition is harder to pin down. It comes only after a long hard struggle with a subject. Eventually you develop an unconscious feel for the subject and this can provide insights not available by formal deduction. The book looks at the use of theories, models, and intuition in a variety of areas such as physics, emotions (Spinoza's Ethics), finance, and economics.
We were very glad to have the opportunity to ask Professor Derman a few questions about his new book and sundry other things. The following interview was conducted by email and completed on Oct 25, 2011.
Q. In your new book you say that freedom is the unification of understanding and volition, of reason and desire (p 106). Does this imply that free will is a faculty that needs to be developed? That people don't have it by default?
A. I was actually channeling Spinoza, what I believe he thought: you are free when you act in accordance with will and reason, i.e. free of conflict. I never thought about whether it's a faculty that needs to be developed, but now that you mention it, I do. And in fact all of Spinoza's Ethics is about how to bring reason and will in accord with each other. (Whether one really has free will -- I don't know. When one says one is acting freely, one doesn't really know why one is acting, is one interpretation.)
Q. There is a new book by David Kaiser called "How the Hippies Saved Physics". In it he talks about how after World War II discussion about the philosophical implications of quantum mechanics was discouraged. Students were basically told to just shut up and calculate. Before the war physicists were more inclined to grapple with the question of what a physical theory said about the nature of reality. Do you think it is important to look at the philosophical implications of a theory?
A. Yes, I read Kaiser's book and loved it. We were pretty much told to shut up and calculate, that philosophy and interpretation of quantum mechanics was something to be done when you were old and past doing productive calculation. There is a recurrence of interest in quantum mechanics now, again, the past thirty years, and it's great. I notice that biologists and neuroscientists often don't understand how peculiar quantum mechanics is, and therefore have an everything-is-simple-down-below kind of feeling.
Q. Dirac once said "A good deal of my research in physics has consisted in not setting out to solve some particular problem, but simply examining mathematical equations of a kind that physicists use and trying to fit them together in an interesting way, regardless of any application that the work may have. It is simply a search for pretty mathematics. It may turn out later to have an application. Then one has good luck." (International Journal of Theoretical Physics, Vol 21, No 8-9, 1982, p 603) He seems to be saying that new theories can be found using mathematical intuition and a sense of mathematical aesthetics. Do you think this is possible in any field other than physics?
A. I think it's true in physics, but it's not as simple as it sounds. Dirac wasn't just searching for beauty, but for constrained beauty that satisfied both relativity and quantum mechanics. Beauty without constraint isn't enough.
I think it's possible in many things to do with human behavior and, to be pretentious, the purpose of life. There is no other way to approach that.
Q. Do you think theories in physics and mathematics are created or discovered? Are you a Platonist?
A. I think they're discovered, if you push me. Yes, I'm a Platonist.
Q. What is it that made you decide to leave physics and go into quantitative finance? Was it a difficult decision?
A. It was happenstance. I couldn't find a job in a city that I wanted to live in compatible with all my other constraints, and so I left physics. I didn't go straight into quantitative finance, but instead went to work at Bell Labs near NYC, as I describe at length in my book "My Life as a Quant". It was a terribly difficult decision; like giving up, it seemed at the time, everything I'd ever aspired to.
Q. In some countries, Israel and China for example, scientists are held in high esteem. In the U.S. most people would be hard pressed to name a single scientist. Do you think American culture is anti-intellectual?
A. I don't think it's ANTI intellectual, though I am impressed, for example, that in Vienna there is a BoltzmanStrasse. Here it's musicians and politicians who have streets named after them. Nevertheless, I don't think the US is anti-intellectual, or at least not the part I live in. I would say it's more no-nonsense than anti-intellectual.
Q. Some physicists have done interesting work in economic modeling. John Blatt, who wrote a well known book on theoretical nuclear physics with Victor Weisskopf, did work on dynamic, i.e. nonequilibrium, economic models. Doyne Farmer is also doing some interesting work. Do you think physicists are better off spending their effort on modeling economic systems instead of working in finance?
A. Doyne Farmer's work is very interesting, and an example of what I think are sensible models and a sensible approach to data analysis, a physicist's approach. I didn't know that about Blatt.
Q. What do you thing about the term "Econophysics"? Is there much to be gained in applying theories and methods originally developed by physicists in order to solve problems in economics or finance?
A. As I argue in my book, the syntax of economics and physics is similar, but the semantics is very different. I try quite hard to explain that in Chapter 5 on the efficient market model. But I still think modeling is useful; one just has to understand how far to trust it. There's no substitute.
Q. Do you consider the following statement by P.A.M. Dirac to be naive? "There is in my opinion a great similarity between the problems provided by the mysterious behavior of the atom and those provided by the present economic paradoxes confronting the world. In both cases one is given a great many facts which are expressible with numbers, and one has to find the underlying principles. The methods of theoretical physics should be applicable to all those branches of thought in which the essential features are expressible with numbers." (Paul A.M. Dirac's speech at the Nobel Banquet in Stockholm, December 10, 1933)
A. No, I find it inspiring. There may be principles underneath, more principles than laws. Spinoza points out that it took centuries to find the laws constraining the planets, and it may take much longer to find those constraining human behavior. They may be more like relationships than laws, in the sense that Pythagoras's theorem is a relationship rather than a law. If pushed though, I would say Dirac's inspiring statement is unlikely to be fulfilled.
Q. How long do you think it will take before economics, as taught in academia, will be worth anything?
A. I don't think it's worth nothing. It's useful; but you have to know, and I try to teach that, how to use it, combining it with common sense and heuristics and a knowledge of how people behave in real life.
Q. For a physicist just starting out in finance today, which areas do you believe are most appropriate for him to apply his efforts?
A. The statistical/stochastic behavior of prices, price formation.
Q. Are there things for which theories simply do not exist? Are there situations where no finite set of formal rules and descriptions can describe exact behavior? Can all behavior in the universe be reduced to an algorithm? If you call something that can be modeled on a computer computational, then are there things which are not computational even in principle?
A. Theories for humans, despite what I wrote optimistically about Spinoza's view, will never be successful in the ways that physics theories are. I don't think everything can be reduced to an algorithm. Underneath everything is our own sense of existence and (some) autonomy. I wrote a blog (http://blogs.reuters.com/emanuelderman/2011/10/12/why-im-right/) recently that expressed this sentiment and then found something similar in a NYR of Books article by the late Saul Bellow, who wrote: Facts must be respected. For reasons I can't explain, my own first consciousness has had a long unbroken history. For people who have no access to any such core consciousness, no mysteries exist.
Q. Mathematically described theories and models can be programmed into a computer. Is intuition, in your opinion, non-computational?
A. Yes, it's wetware, physical, maybe even nonphysical, but non computational.
Q. Marvin Minsky has written that "if the nervous system obeys the laws of physics and chemistry, which we have every reason to suppose it does, then .... we ... ought to be able to reproduce the behavior of the nervous system with some physical device." Do you think that those who believe that computers can be programmed to exhibit behavior that is indistinguishable from humans are engaging in pragmamorphism?
A. We are a physical device, so it should be possible to build something like us; program something like us is a different statement, and that may be pragmamorphic.
Q. Do you still enjoy programming computers? and if so, what kinds of programs do you write, and in what language(s)?
A. I don't program much any more, and when I do it's mostly for work or teaching, in Matlab. I did love programming though, when I did it, in C, lex, yacc, awk, and I liked writing interpreters most.
Q. In your first book, you describe being introduced to meditation in Boulder. Do you still practice it? and if so how has it benefited you?
A. Only very occasionally, I regret to say. It helps in recognizing that your concerns are not those of everyone else's, that everyone is just as important to themself as you seem to yourself, and so putting one's own miseries (and I suppose joys) in perspective.
Q. Dennis Ritchie, co-developer of the C-programming language and the Unix operating system has recently died. Did you have any interaction with him, or Ken Thompson, or Brian Kernighan at Bell Labs?
A. Never directly. But I was and am a great UNIX fan, used all their tools. Fantastic the way they saw programming as a human endeavor to both create and to do it in a clear readable way.
- Stefan Hollos and Richard Hollos