File size: 310,530 Bytes
6c323a9
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
{"id": "finance_111", "domain": "finance", "question_title": "How can I go about applying machine learning algorithms to stock markets?", "question_body": "Can anyone share their experience and basic pointers about how to go about it or at least start applying it to see results from data sets? How ambitious is this? Also, mention standard algorithms that should be investigated.", "question_score": 146, "question_tags": ["machine-learning", "prediction", "mathematics"], "choices": {"A": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters....", "B": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "C": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "D": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/111/how-can-i-go-about-applying-machine-learning-algorithms-to-stock-markets"}
{"id": "finance_1027", "domain": "finance", "question_title": "How are correlation and cointegration related?", "question_body": "In what ways (and under what circumstances) are correlation and cointegration related, if at all? One difference is that one usually thinks of correlation in terms of returns and cointegration in terms of price. Another issue is the different measures of correlation (Pearson, Spearman, distance/Brownian) and cointegration (Engle/Granger and Phillips/Ouliaris).", "question_score": 64, "question_tags": ["time-series", "statistics", "correlation", "cointegration"], "choices": {"A": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "B": "The term has a different meaning to different people. to econometricians, microstructure noise is a disturbance that makes high frequency estimates of some parameters (e.g. realized volatility) very unstable. Generally this strand of the literature professes agnosticism as to the its origin; to market microstructure researchers, microstructure noise is a deviation from fundamental value that is induced by the characteristics of the market under consideration, e.g. bid-ask bounce, the discreteness of price change, latency, and asymmetric information of traders. The last example is frequently cited but I don't think it is accurate. Asymmetric information does not have to be a...", "C": "Just to be painfully clear, it only seems to make sense to consider the logarithm of returns, i.e. $X=\\log (1+\\frac r{100})$ for a simple return of $r\\%$ in an arbitrary period because this is what sums when returns are temporally aggregated. A basic property of cumulants is that cumulants of all orders are additive under convolution, for which a proof can be found here here . So if $X_1$, $X_2$, ... $X_n$ are i.i.d. , then all the cumulants of $$Y_n = \\sum_{i=1}^nX_i$$ scale linearly with $n$, i.e. $$\\kappa_k(Y_n)=n\\kappa_k(Y_1).$$ However, I suspect that you are normalizing this sum so that...", "D": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)"}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1027/how-are-correlation-and-cointegration-related"}
{"id": "finance_545", "domain": "finance", "question_title": "How useful is the genetic algorithm for financial market forecasting?", "question_body": "There is a large body of literature on the \"success\" of the application of evolutionary algorithms in general, and the genetic algorithm in particular, to the financial markets. However, I feel uncomfortable whenever reading this literature. Genetic algorithms can over-fit the existing data. With so many combinations, it is easy to come up with a few rules that work. It may not be robust and it doesn't have a consistent explanation of why this rule works and those rules don't beyond the mere (circular) argument that \"it works because the testing shows it works\". What is the current consensus on the application of the genetic algorithm in finance?", "question_score": 59, "question_tags": ["quant-trading-strategies", "forecasting", "algorithm"], "choices": {"A": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "B": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a...", "C": "By \"cryptography\" you mean information theory. Information theory is useful for portfolio optimization and for optimally allocating capital between trading strategies (a problem which is not well addressed by other theoretical frameworks.) See: --- J. L. Kelly, Jr., \"A New Interpretation of Information Rate,\" Bell System Technical Journal, Vol. 35, July 1956, pp. 917-26 --- E. T. Jaynes, Probability Theory: The Logic of Science http://amzn.to/dtcySD --- http://en.wikipedia.org/wiki/Gambling_and_information_theory http://en.wikipedia.org/wiki/Kelly_criterion In the simple case, you would use \"The Kelly Rule\". More complicated information theory based strategies for allocating capital between trading strategies take into account correlations between the performance of trading strategies...", "D": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/545/how-useful-is-the-genetic-algorithm-for-financial-market-forecasting"}
{"id": "finance_8247", "domain": "finance", "question_title": "Why Drifts are not in the Black Scholes Formula", "question_body": "This question has puzzled me for a while. We all know geometric brownian motions have drifts $\\mu$: $dS / S = \\mu dt + \\sigma dW$ and different stocks have different drifts of $\\mu$. Why would the drifts go away in Black Scholes? Intuitively, everything else being equal, if a stock has higher drift, shouldn't it have higher probability of finishing in-the-money (and higher probability of having higher payoff), and the call option should be worth more? Is there an intuitive and easy-to-understand answer? thanks.", "question_score": 55, "question_tags": ["options", "option-pricing", "black-scholes", "risk-neutral-measure"], "choices": {"A": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "B": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "C": "A general model (with continuous paths) can be written $$ \\frac{dS_t}{S_t} = r_t dt + \\sigma_t dW_t^S $$ where the short rate $r_t$ and spot volatility $\\sigma_t$ are stochastic processes. In the Black-Scholes model both $r$ and $\\sigma$ are deterministic functions of time (even constant in the original model). This produces a flat smile for any expiry $T$. And we have the closed form formula for option prices $$ C(t,S;T,K) = BS(S,T-t,K;\\Sigma(T,K)) $$ where $BS$ is the BS formula and $\\Sigma(T,K) = \\sqrt{\\frac{1}{T-t}\\int_t^T \\sigma(s)^2 ds}$. This is not consistent with the smile observed on the market. In order to match...", "D": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/8247/why-drifts-are-not-in-the-black-scholes-formula"}
{"id": "finance_1501", "domain": "finance", "question_title": "Which approach dominates? Mathematical modeling or data mining?", "question_body": "According to my current understanding, there is a clear difference between data mining and mathematical modeling . Data mining methods treat systems (e.g., financial markets) as a \"black box\". The focus is on the observed variables (e.g., stock prices). The methods do not try to explain the observed phenomena by proposing underlying mechanisms that cause the phenomena (i.e., what happens in the black box). Instead, the methods try to find some features, patterns, or regularities in the data in order to predict future behavior. Mathematical modeling , in contrast, tries to propose a model for what happens inside the black box. Which approach dominates in quantitative finance? Do people try to use more and more fancy data mining techniques or do people try to construct better and better mathematical models?", "question_score": 52, "question_tags": ["modeling", "market", "data-mining"], "choices": {"A": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "B": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we...", "C": "I would offer the distinctions are i) pure statistical approach, ii) equilibrium based approach, and iii) empirical approach. The statistical approach includes data mining. Its techniques originate in statistics and machine learning. In its extreme there is no a priori theoretical structure imposed on asset returns. Factor structure might be identified thru Principal Components, for example. The goal here is to maximize predictive accuracy at the expense of intuition and explanatory power. This approach increasingly dominates at very short frequencies in modeling market microstructure, market making algorithms, volatility modeling, etc. However, even in high-frequency trading one can impose a factor...", "D": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1501/which-approach-dominates-mathematical-modeling-or-data-mining"}
{"id": "finance_1565", "domain": "finance", "question_title": "How do I graphically represent the evolution of a covariance matrix over time?", "question_body": "I am working with a set of covariance matrices evaluated at various points in time over some history. Each covariance matrix is $N\\times N$ for $N$ financial time-series over $T$ periods. I would like to explore some of the properties of this matrix's evolution over time, particularly whether correlation as a whole is increasing or decreasing, and whether certain series become more or less correlated with the whole. I am looking for suggestions as to the kinds of analysis to perform on this data-set, and particularly graphical/pictorial analysis. Ideally, I would like to avoid having to look in depth into each series as $N$ is rather large. Update The following graphs were generated based on the accepted answer from @Quant-Guy. PC = principal component = eigenvector. The analysis was done on correlations rather than covariances in order to account for vastly different variances of the $N$ series.", "question_score": 51, "question_tags": ["time-series", "correlation", "covariance"], "choices": {"A": "Representing time series (esp. tick data) using elaborate data structures may be not the best idea. You may want to try to use two arrays of the same length to store your time series. The first array stores values (e.g. price) and the second array stores time. Note that the second series is monotonically increasing (or at least non-decreasing), i.e. it's sorted. This property enables you to search it using the binary search algorithm. Once you get an index of a time of interest in the second array you also have the index of the relevant entry in the first...", "B": "It is hard to find a stable non-trivial dependence structure in financial data. Usually when such is found it is hard to rationalize. One of my favorite (although I am sure there are others) is the so called \"Presidential Puzzle\". This is an old finding by Santa-Clara and Valkanov (2003) They find that \" Excess return in the stock market is higher under Democratic than Republican presidencies: 9 percent for the value‐weighted and 16 percent for the equal‐weighted portfolio. At the time the finding was very robust and did not seem to be explained by anything else. What is more...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "I would consider a motion chart that plots the eigenvalues of the covariance matrix over time. For a static view you can create a table: rows represent dates, and columns represent eigenvectors. The entries of the table represent changes in the angle of the eigenvector from the previous row. This will show how stable your covariance structure is. You can also create a second table this time with eigenvalues as the columns sorted from high to low (and the corresponding values below for each date). This shows the variance described by each eigenvector so you can see whether correlation as..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1565/how-do-i-graphically-represent-the-evolution-of-a-covariance-matrix-over-time"}
{"id": "finance_1891", "domain": "finance", "question_title": "How much data is needed to validate a short-horizon trading strategy?", "question_body": "Suppose one has an idea for a short-horizon trading strategy, which we will define as having an average holding period of under 1 week and a required latency between signal calculation and execution of under 1 minute. This category includes much more than just high-frequency market-making strategies. It also includes statistical arbitrage, news-based trading, trading earnings or economics releases, cross-market arbitrage, short-term reversal/momentum, etc. Before even thinking about trading such a strategy, one would obviously want to backtest it on a sufficiently long data sample. How much data does one need to acquire in order to be confident that the strategy \"works\" and is not a statistical fluke? I don't mean confident enough to bet the ranch, but confident enough to assign significant additional resources to forward testing or trading a relatively small amount of capital. Acquiring data (and not just market price data) could be very expensive or impossible for some signals, such as those based on newer economic or financial time-series. As such, this question is important both for deciding what strategies to investigate and how much to expect to invest on data acquisition. A complete answer should depend on the expected Information Ratio of the strategy, as a low IR strategy would take a much longer sample to distinguish from noise.", "question_score": 51, "question_tags": ["data", "time-series", "backtesting", "quant-trading-strategies", "arbitrage"], "choices": {"A": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "B": "Strictly speaking, data snooping is not the same as in-sample vs out-of-sample model selection and testing, but has to deal with sequential or multiple tests of hypothesis based on the same data set. To quote Halbert White: Data snooping occurs when a given set of data is used more than once for purposes of inference or model selection. When such data reuse occurs, there is always the possibility that any satisfactory results obtained may simply be due to chance rather than to any merit inherent in the methody yielding the results. Let me provide an example. Suppose that you have...", "C": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident...", "D": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)"}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1891/how-much-data-is-needed-to-validate-a-short-horizon-trading-strategy"}
{"id": "finance_85", "domain": "finance", "question_title": "Are there any new Option pricing models?", "question_body": "Back in the mid 90's I used the Black-Scholes Model and the Cox-Ross-Rubenstein (Binomial) Model's to price Options. That was nearly 15 years ago and I was wondering if there are any new models being used to price Options?", "question_score": 50, "question_tags": ["black-scholes", "option-pricing"], "choices": {"A": "Black-Scholes itself didn't change a lot but we can now adjust it to deal with a lot more complicated factors to price more complicated contracts: stochastic volatility (Heston, Gatheral) stochastic rates (Hull) credit risk dividends Other methods (computing intensive) have also evolved to deal with various types of contracts where BS is not very appropriate choice (e.g. Monte Carlo simulation for path-dependant options).", "B": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "C": "The way you do it in the first place is a discretization of the Geometric Brownian Motion (GBM) process. This method is most useful when you want to compute the path between $S_0$ and $S_t$, i.e. you want to know all the intermediary points $S_i$ for $0 \\leq i \\leq t$. The second equation is a closed form solution for the GBM given $S_0$. A simple mathematical proof showed that, if you know the initial point $S_0$ (which is $a$ in your equation), then the value of the process at time $t$ is given by your equation (which contains $W_t$,...", "D": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/85/are-there-any-new-option-pricing-models"}
{"id": "finance_1274", "domain": "finance", "question_title": "How can we reverse engineer a market-making algorithm (HFT)?", "question_body": "Consider a market participant $A$ who is mechanically following an automated liquidity providing algorithm (HFT) in a number of large cap stocks on a specific exchange. Assume furthermore that we are able to observe all orders placed by $A$ and that we know that the algorithm used by $A$ takes only public market data as input. $A$ starts and ends all trading days with zero inventory. We want to reverse engineer the algorithm used by $A$. Let's call this algorithm $f(...)$. The first step in reverse engineering the algorithm $f(...)$ would be to collect potential input variables to the algorithm that can later be used to infer the exact form of $f(...)$. The first problem we face is which input variables we should collect in order to be able to reverse engineer $f(...)$. To have a starting point we can consider the input variables used in Avellaneda & Stoikov (2008) . In Avellaneda & Stoikov (2008) the authors derive how a rational market maker (non-specialist) should set his bid and ask quotes in a limit order book market. The results are obviously contingent on the assumptions and model choices made in the paper. The optimal bid (or ask) in Avellaneda & Stoikov (2008) is a function of the following inputs: The trader's reservation price, which is a function of the security price ($S$), the market maker's current inventory ($q$) and time left until terminal holding time ($T-t$) The relative risk aversion of the trader ($\\gamma$) (obviously hard to observe!) The frequency of new bid and ask quotes ($\\lambda_{bid}$ and $\\lambda_{ask}$) The latest change in frequency of new bid and ask quotes ($\\delta\\lambda_{bid}$ and $\\delta\\lambda_{ask}$) What potential input variables should we collect in order to be able to reverse engineer $f(...)$?", "question_score": 50, "question_tags": ["trading", "algorithmic-trading", "high-frequency", "market-microstructure"], "choices": {"A": "I'll take a stab at it, but this is a really broad question. A direct answer: Bayesian models often use \"probability that the counter-party is informed.\" Indirect answers: I think your assumption is that the algorithm operates on each stock individually, and has no knowledge of what it's doing in any other stock. But, it is likely that the algorithm is doing some hedging that you don't see yet. You should look at similar products (or build synthetic baskets) and see if your algorithm is changing it's quote sizes/prices when other products' quote sizes/prices change. (It is also possible that...", "B": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "C": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters....", "D": "The lead paper in the January 2011 Journal of Finance ( Hendershott, Jones, and Menkveld ) addresses algorithmic trading (AT). In short, they find that AT improves liquidity as measured by bid-offer spreads. Taking the econometrics as correct (it is in the Journal of Finance) the next question is if bid-offer spreads are a sufficient statistic for measuring liquidity (or any other benefits). It is a difficult question to answer because, given current market structure, AT may improve liquidity (as measured by bid-offer spreads), but without data on other market structures, it is hard to say that we wouldn't better..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1274/how-can-we-reverse-engineer-a-market-making-algorithm-hft"}
{"id": "finance_2074", "domain": "finance", "question_title": "What is the best way to "fix" a covariance matrix that is not positive semi-definite?", "question_body": "I have a sample covariance matrix of S&P 500 security returns where the smallest k-th eigenvalues are negative and quite small (reflecting noise and some high correlations in the matrix). I am performing some operations on the covariance matrix and this matrix must be positive definite. What is the best way to \"fix\" the covariance matrix? (For what it's worth, I intend to take the inverse of the covariance matrix.) One approach proposed by Rebonato (1999) is to decompose the covariance matrix into its eigenvectors and eigenvalues, set the negative eigenvalues to 0 or (0+epsilon), and then rebuild the covariance matrix. The issue I have with this method is that: the trace of the original matrix is not preserved, and the method ignores the idea of level repulsion in random matrices (i.e. that eigenvalues are not close to each other). Higham (2001) uses an optimization procedure to find the nearest correlation matrix that is positive semi-definite. Grubisic and Pietersz (2003) have a geometric method they claim outperforms the Higham technique. Incidentally, some more recent twists on Rebonato's paper are Kercheval (2009) and Rapisardo (2006) who build off of Rebonato with a geometric approach. A critical point is that the resulting matrix may not be singular (which can be the case when using optimization methods). What is the best way to transform a covariance matrix into a positive definite covariance matrix? UPDATE: Perhaps another angle of attack is to test whether a security is linearly dependent on a combination of securities and removing the offender.", "question_score": 49, "question_tags": ["risk", "statistics", "research", "correlation", "covariance"], "choices": {"A": "Nick Higham's specialty is algorithms to find the nearest correlation matrix. His older work involved increased performance (in order-of-convergence terms) of techniques that successively projected a nearly-positive-semi-definite matrix onto the positive semidefinite space. Perhaps even more interesting, from the practitioner point of view, is his extension to the case of correlation matrices with factor model structures. The best place to look for this work is probably the PhD thesis paper by his doctoral student Ruediger Borsdorf. Higham's blog entry covers his work up to 2013 pretty well.", "B": "I'm just providing a global answer to the question, as I think it can be interesting for some beginners in quant finance. The properties given by TheBridge: Normalize $\\rho (\\emptyset)=0$ This means you have no risk in taking no position. Sub-addiitivity $\\rho(A_1+A_2) \\leq \\rho(A_1)+\\rho(A_2)$ Having a position in two different can only decrease the risk of the portfolio (diversification) Positive homogeneity $\\rho(\\lambda A) = \\lambda \\rho(A)$ Doubling a position in an asset A doubles your risk. And finally, Translation invariance $\\rho(A + x) = \\rho(A)-x$ That is, adding cash to a portfolio only diminishes the risk. So a risk-measure is...", "C": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "D": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)"}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2074/what-is-the-best-way-to-fix-a-covariance-matrix-that-is-not-positive-semi-defi"}
{"id": "finance_115", "domain": "finance", "question_title": "Lévy alpha-stable distribution and modelling of stock prices.", "question_body": "Since Mandelbrot, Fama and others have performed seminal work on the topic, it has been suspected that stock price fluctuations can be more appropriately modeled using Lévy alpha-stable distrbutions other than the normal distribution law. Yet, the subject is somewhat controversial, there is a lot of literature in defense of the normal law and criticizing distributions without bounded variation. Moreover, precisely because of the the unbounded variation, the whole standard framework of quantitative analysis can not be simply copy/pasted to deal with these more \"exotic\" distributions. Yet, I think there should be something to say about how to value risk of fluctuations. After all, the approaches using the variance are just shortcuts, what one really has in mind is the probability of a fluctuation of a certain size. So I was wondering if there is any literature investigating that in particular. In other words: what is the current status of financial theories based on Lévy alpha-stable distributions? What are good review papers of the field?", "question_score": 47, "question_tags": ["risk", "equities", "variance", "probability"], "choices": {"A": "I recently read \"Modeling financial data with stable distributions\" (Nolan 2005) which gives a survey of this area and might be of interest (I believe it was contained in \"Handbook of Heavy Tailed Distributions in Finance\" ). Another more recent reference is \"Alpha-Stable Paradigm in Financial Markets\" (2008). I'm not aware of anything covering \"risk of fluctuations\" and this is still certainly not at the center of the field (i.e. most theory still includes some version of Gaussian or mixture of Gaussians). Would also be interested in other references.", "B": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a...", "C": "From what I remember, there is no real relation between Markov and Martingale, and my intuition was confirmed by this post . Basically, it says that you can say neither of the following: If A is Markov, then A is a martingale. If A is a martingale, then A is Markov. further down the post, you can find two counter examples: $dX_t = a dt + \\sigma dW_t$ is Markov but not a martingale and $dX_t = (\\int_0^t X_s ds) dW_t$ is a Martingale but is not Markov. As for the assumption of these properties being true, I think it...", "D": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/115/l%c3%a9vy-alpha-stable-distribution-and-modelling-of-stock-prices"}
{"id": "finance_9313", "domain": "finance", "question_title": "Machine Learning vs Regression and/or Why still use the latter?", "question_body": "I come from a different field (Machine learning/AI/data science), but aim to ask a philosophical question with the utmost respect: Why do quantitative financial analysts (analysts/traders/etc.) prefer (or at least seem) traditional statistical methods (traditional = frequentist/regression/normal correlation methods/ts analysis) over newer AI/machine learning methods? I've read a million models, but it seems biased? Background: I recently joined a 1B AUM (I know it's not a ton) asset management firm. I was asked to build a new model for a sector rotation strategy (basically predicting which SP 500 sector would do the best over 6 months-- chose to use forward rolling 6 month returns) they employ and my first inclination was to combine ARIMA (traditional) with random forest (feature selection) and a categorical (based on normal distribution standard deviation) gradient boosted classifier for ETFs in each sector. Not to be rude, but I beat the ValuLine timeliness for each sector. I used the above mentioned returns as my indicator and pretty much threw everthing at the wall for predictors initially (basically just combing FRED), then used randomForest to select features. I ended up combining EMA and percent change to create a pretty solid model that, like I said, beat ValuLine. I've read a lot of literature, and I haven't seen anyone do anything like this. Any help in terms of pointing me in the right direction for literature? Or any answers to the overarching idea of why isn't there more machine learning in equity markets (forgetting social/news analysis)? EDIT: For clarification, I'm really interested in long-term predictions (I think Shiller was right) based on macro predictors. Thanks PS- I've been lurking for a while. Thanks for all the awesome questions, answers, and discussions.", "question_score": 46, "question_tags": ["equities", "regression", "machine-learning"], "choices": {"A": "In order to answer your question (for you) you would need something to compare to . You would need numbers to know if it is slower/faster, how much, and if it will impact your system overall. Also knowing your performance goals could narrow down the options. My advice is to take a look at your overall architecture of the sytem you have or intend to build. To just look at QuickFIX is rather meaningless without the whole chain involved in processing information and reacting to it . As an example, say QuickFIX is 100 times faster than some part (in...", "B": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "C": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "D": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/9313/machine-learning-vs-regression-and-or-why-still-use-the-latter"}
{"id": "finance_2870", "domain": "finance", "question_title": "Why does the minimum variance portfolio provide good returns?", "question_body": "I've been a researching minimum variance portfolios (from this link ) and find that by building MVPs adding constraints on portfolio weights and a few other tweaks to the methods outlined I get generally positive returns over a six-month to one year time scale. I am looking to build some portfolios that are low risk, but have good long term (yearly) expected returns. MVP (as in minimum variance NOT mean variance) seems promising from backtests but I don't have a good intuition for why this works. I understand the optimization procedure is primarily looking to optimize for reducing variance, and I see that this works in the backtest (very low standard deviation of returns). What I don't have an intuitive feel for is why optimizing variance alone (with no regards to optimizing returns, i.e. no mean in the optimization as in traditional mean-variance optimization) gives generally positive returns. Any explanations?", "question_score": 45, "question_tags": ["portfolio-management", "optimization", "modern-portfolio-theory", "covariance"], "choices": {"A": "Short of having a 'reasonable' predictive model for expected returns and the covariance matrix, there are a couple lines of attack. Shrinkage estimators (via Bayesian inference or Stein-class of estimators) Robust portfolio optimization Michaud's Resampled Efficient Frontier Imposing norm constraints on portfolio weights Naively, shrinkage methods 'shrink' (of course,no?) your estimates (arrived at using historical data), toward some global mean or some target. Within the mean-variance framework, you can use the shrinkage estimators, for both, the expected returns vector, as well as the covariance matrix. Jorion introduced application of a 'Bayes-Stein estimator' to portfolio analysis. Bradley & Efron have a...", "B": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)"}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2870/why-does-the-minimum-variance-portfolio-provide-good-returns"}
{"id": "finance_17125", "domain": "finance", "question_title": "How to build a factor model?", "question_body": "Factor models such as Fama-French or the other ones that are partially summarized here work on the cross-section of asset returns. How are the factors built, how are sensitivities/coefficients estimated? In this context Fama-MacBeth regressions are usually mentioned. How does this method work intuitively? Could anyone give a step-by-step manual? EDIT: Links to papers and manuals have been posted in the two answers - this is great. But can someone provide more intuition in the answer? Say we have a universe of stocks (say MSCI Europe) and we group them by value and size. How can we proceed? How do we construct the factors and how do we construct the sensitivities? Could someone please give a more direct explanation, without a link? thanks!", "question_score": 44, "question_tags": ["regression", "factor-models", "fama-french"], "choices": {"A": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a...", "B": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "C": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "D": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$...."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/17125/how-to-build-a-factor-model"}
{"id": "finance_1658", "domain": "finance", "question_title": "Has high frequency trading (HFT) been a net benefit or cost to society?", "question_body": "Various studies have demonstrated the very large and growing influence of high frequency trading (HFT) on the markets. HFT firms are clearly making a great deal of money from somewhere, and it stands to reason that they are making this money at the expense of every other participant in the market. Defenders of HFT will argue that HFT firms provide an essential service to the economy in the form of greater liquidity. What research has been done on the benefits and costs of HFT? Has any study attempted to measure either the benefits or the costs? How would one attempt to measures these benefits and costs? What would be the effect of banning rapidly cancelled limit orders (see follow-up question ), e.g. via a minimum 1-second tick rule? Any references and professional opinions (backed by research) on this topic would be appreciated.", "question_score": 42, "question_tags": ["algorithmic-trading", "research", "high-frequency", "market-microstructure"], "choices": {"A": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "B": "The lead paper in the January 2011 Journal of Finance ( Hendershott, Jones, and Menkveld ) addresses algorithmic trading (AT). In short, they find that AT improves liquidity as measured by bid-offer spreads. Taking the econometrics as correct (it is in the Journal of Finance) the next question is if bid-offer spreads are a sufficient statistic for measuring liquidity (or any other benefits). It is a difficult question to answer because, given current market structure, AT may improve liquidity (as measured by bid-offer spreads), but without data on other market structures, it is hard to say that we wouldn't better...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "I can think of an application in options pricing. I came across the following paper a long time ago but think it explains FT very eloquently as applied to pricing options under BS: http://maxmatsuda.com/Papers/2004/Matsuda%20Intro%20FT%20Pricing.pdf The fun starts on page 112 but it relies on the 1998 paper by Madan and Carr. What I like about the paper is that it gives a thorough introduction to FT and only when the groundwork is set it applies it to option pricing. Not a bad approach vs many other papers which make a lot of assumption and assume the reader can jump right..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1658/has-high-frequency-trading-hft-been-a-net-benefit-or-cost-to-society"}
{"id": "finance_8274", "domain": "finance", "question_title": "How to estimate real-world probabilities", "question_body": "In the world of finance, Risk-neutral pricing allow us to estimate the fair value of derivatives using the risk free rate as the expected return of the underlyings. However, the behavior of financial assets in the real-world might be substantially different to the evolution used in a risk-neutral context. For instance, if I want to estimate the real-world probability of an equity asset reaching certain thresholds, which models and calibration techniques could be used? In particular, some questions that may arise in the estimation of real-world probabilities are: Calibration : Should real-world probabilities be calibrated to current market prices or, alternative, historical data should be used for this type of estimation? No-arbitrage conditions : Could they be relaxed or they still play a role in the assessment of real-world probabilities? Expected returns : Assuming that I have already estimated the expected return of an asset $\\mu$, how accurate would be a real-world estimation that combines a widely used evolution model (e.g. Geometric Brownian motion ), with the use of $\\mu$ instead of the risk free rate $r$? Per comments, I understand that in order to estimate real-world probabilities: I should use expected returns instead of the risk-free rate. The asset evolution should still respect the no-arbitrage conditions (i.e: the real-world dynamics should still reproduce the current prices of vanilla options). However, if we just use $\\mu$ instead of $r$, the underlying asset behavior might not be consistent with the observed option prices. For instance, if we just change $r$ by $\\mu$ (with $\\mu>r$) the underlying asset dynamics will lead to call prices above its current market price, and put prices below its market price. Therefore, in addition to use expected returns, which other adjustment might be needed in order to estimate real-world probabilities? Any papers or references regarding real-world estimation will be greatly appreciated.", "question_score": 42, "question_tags": ["derivatives", "risk-neutral-measure", "forecasting", "stochastic-discount", "real-world-measure"], "choices": {"A": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "B": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters....", "C": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "D": "A general model (with continuous paths) can be written $$ \\frac{dS_t}{S_t} = r_t dt + \\sigma_t dW_t^S $$ where the short rate $r_t$ and spot volatility $\\sigma_t$ are stochastic processes. In the Black-Scholes model both $r$ and $\\sigma$ are deterministic functions of time (even constant in the original model). This produces a flat smile for any expiry $T$. And we have the closed form formula for option prices $$ C(t,S;T,K) = BS(S,T-t,K;\\Sigma(T,K)) $$ where $BS$ is the BS formula and $\\Sigma(T,K) = \\sqrt{\\frac{1}{T-t}\\int_t^T \\sigma(s)^2 ds}$. This is not consistent with the smile observed on the market. In order to match..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/8274/how-to-estimate-real-world-probabilities"}
{"id": "finance_557", "domain": "finance", "question_title": "How fast is QuickFix ?", "question_body": "In my firm we are beginning a new OMS (Order Management System) project and there is a debate whether we use Quickfix or we go for a professional fix engine? Because there is a common doubt that QuickFix is not enough fast and obviously we will not get any technical support. I heard that in BOVESPA it has been used for a while. They are changing it with a paid one now. Well that is enough for me. If they use it I can use it. Should I choose a professional one over QuickFix? Is it not good enough?", "question_score": 41, "question_tags": ["fix"], "choices": {"A": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "B": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "C": "In order to answer your question (for you) you would need something to compare to . You would need numbers to know if it is slower/faster, how much, and if it will impact your system overall. Also knowing your performance goals could narrow down the options. My advice is to take a look at your overall architecture of the sytem you have or intend to build. To just look at QuickFIX is rather meaningless without the whole chain involved in processing information and reacting to it . As an example, say QuickFIX is 100 times faster than some part (in...", "D": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/557/how-fast-is-quickfix"}
{"id": "finance_25942", "domain": "finance", "question_title": "Why aren't econometric models used more in Quant Finance?", "question_body": "There is a big body of literature on econometric models like ARIMA , ARIMAX or VAR . Yet to the best of my knowledge practically nobody is making use of that in Quantitative Finance. Yes, there is a paper here and there and sometimes you find an example where stock prices are being used for illustrative purposes but this is far from the main stream. My question Is there a good reason for that? Is it just because of tradition and different schools of thought or is there a good technical explanation? (By the way I was pleased to find an arima tag here... but this is again a case in point: only 8 out of nearly 7,000 questions (~ 0.1% !) use this tag! ...ok, make this 9 now ;-)", "question_score": 41, "question_tags": ["modeling", "forecasting", "econometrics", "models", "arima"], "choices": {"A": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "B": "I know that I have seen things like this in the past. Wasn't there something recently that used Twitter? Here are a few recent papers as examples, although I will be brutally honest that I don't know if they speak to your decent quality requirement: \"Trading Strategies to Exploit Blog and News Sentiment\" (Zhang, Skiena 2010) \"The Predictive Power of Financial Blogs\" (Frisbee 2010) \"An analysis of verbs in financial news articles and their impact on stock price\" (Schumaker 2010)", "C": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "D": "It's an interesting question. I particularly agree with the $\\mathbb{Q}-\\mathbb{P}$ dichotomy mentioned by many. I would add to the other answers that, come to think of it, the Black-Scholes postulated Geometric Brownian Motion could be interpreted as an AR(1) process on the logarithm of the stock price as you discretise the SDE from which it is a solution, which is exactly what you do when running Monte-Carlo simulations (same thing for the Ornstein-Uhlenbeck process as explained here and noted by @Richard). Actually, when taking the continuous-time limit, many more econometric models can be shown to correspond to stochastic processes frequently..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/25942/why-arent-econometric-models-used-more-in-quant-finance"}
{"id": "finance_1489", "domain": "finance", "question_title": "How should I calculate the implied volatility of an American option in a real-time production environment?", "question_body": "There are many models available for calculating the implied volatility of an American option. The most popular method, employed by OptionMetrics and others, is probably the Cox-Ross-Rubinstein model. However, since this method is numerical, it yields a computationally intensive algorithm which may not be feasible (at least for my level of hardware) for repeated re-calculation of implied volatility on a hundreds of option contracts and underlying instruments with ever-changing prices. I am looking for an efficient and accurate closed form algorithm for calculating implied volatility. Does anyone have any experience with this problem? The most popular closed-form approximation appears to be Bjerksund and Stensland (2002), which is recommended by Matlab as the top choice for American options, although I've also seen Ju and Zhong (1999) mentioned on Wilmott . I am interested in knowing which of these (or other) methods gives the most reasonable and accurate approximations in a real-world setting.", "question_score": 39, "question_tags": ["option-pricing", "implied-volatility"], "choices": {"A": "The way you do it in the first place is a discretization of the Geometric Brownian Motion (GBM) process. This method is most useful when you want to compute the path between $S_0$ and $S_t$, i.e. you want to know all the intermediary points $S_i$ for $0 \\leq i \\leq t$. The second equation is a closed form solution for the GBM given $S_0$. A simple mathematical proof showed that, if you know the initial point $S_0$ (which is $a$ in your equation), then the value of the process at time $t$ is given by your equation (which contains $W_t$,...", "B": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "C": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "D": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1489/how-should-i-calculate-the-implied-volatility-of-an-american-option-in-a-real-ti"}
{"id": "finance_7568", "domain": "finance", "question_title": "Mapping symbols between tickers, Reuters RICs and Bloomberg tickers", "question_body": "Is there any known solution (preferably open source) to map between ticker symbols, Reuters and Bloomberg symbols. For example: Ticker: AAPL Reuters: AAPL.O (may be prefixed with RSF.ANY. dependent upon infrastructure) Bloomberg: AAPL US Equity Edit: by mapping I mean translating from one symbol naming convention to another. For example let's say we have RSF.ANY.AAPL.O and want to get Bloomber equivalent, which is \"AAPL US Equity\". Edit2: Fixed Bloomber mapping, it should be \"AAPL US Equity\" not \"AAPL:US\"", "question_score": 39, "question_tags": ["market-data", "tick-data", "bloomberg", "reuters"], "choices": {"A": "Here are some pointers. First of all: What you list as a Reuters RIC, RSF.ANY.AAPL.OQ , is not really a RIC, only the AAPL.OQ is. The initial part is some stuff which is essentially site specific and tells me that you are working on a site that has a legacy RTIC infrastructure (some Reuters/TIBCO technology which is quite old these days and for all practical purposes has been deprecated in favour of other distribution mechanisms, most notably the ADS). Ok, the AAPL.OQ is the RIC, and only that. The initial part, the RSF.ANY denotes the feed and that is because...", "B": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "C": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "D": "From my experience, EODData is pretty much that you get what you pay for. Its not a very sophisticated product. They email you the files you subscribe to, and thats that. I have had an issue before of where the emails didn't go through anymore and I never heard anything from them. On Quality, I can't make a claim on its accuracy. It seems good. I find issue with three things about the data: There is no way to signal an exchange change It doesn't give you an easy way to grab the symbol info [Names, etc] If there is..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/7568/mapping-symbols-between-tickers-reuters-rics-and-bloomberg-tickers"}
{"id": "finance_946", "domain": "finance", "question_title": "What type of investor is willing to be short gamma?", "question_body": "As far as I understand, most investors are willing to buy options (puts and calls) in order to limit their exposure to the market in case it moves against them. This is due to the fact that they are long gamma. Being short gamma would mean that the exposure to the underlying becomes more long as the underlying price drops and more short as the underlying price rises. Thus exposure gets higher with a P&L downturn and lower with a P&L upturn. Hence I wonder who is willing to be short gamma? Is it a bet on a low volatility? Also, for a market maker in the option market, writing (selling) an option means being short gamma, so if there is no counterparty willing to be short gamma, how are they going to hedge their gamma?", "question_score": 38, "question_tags": ["options", "hedging", "portfolio-management", "greeks", "investing"], "choices": {"A": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "B": "Great question! I think the most useful starting point is Stock Return Characteristics, Skew Laws, and the Differential Pricing of Individual Equity Options by Bakshi, Kapadia and Madan (2003) . Their paper proposes a definition of model-free implied skewness (they originally called it risk-neutral skewness, but MFIS is more accurate), which they prove will have a P&L directly proportional to the realized skewness of the underlier. Subsequent papers (there are literally dozens) have thoroughly explored the properties of MFIS. In particular, Does Risk-Neutral Skewness Predict the Cross-Section of Equity Option Portfolio Returns? by Bali and Murray (2011) estimates the empirical...", "C": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a...", "D": "Being short gamma simply means that you are short options regardless of whether they are puts or calls. The most common type of investor that is willing to be short gamma is someone who sells options, also known as a premium collector. These investors commonly use strategies such as short puts, covered calls, iron condors, vertical credit spreads, and a few others. These strategies are typically referred to as income generation strategies. They offer the investor a return known in advance, in exchange for the risk of being short options. Frequently these types of income trades have have a probability..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/946/what-type-of-investor-is-willing-to-be-short-gamma"}
{"id": "finance_140", "domain": "finance", "question_title": "What are the popular methodologies to minimize data snooping?", "question_body": "Are there common procedures prior or posterior backtesting to ensure that a quantitative trading strategy has real predictive power and is not just one of the thing that has worked in the past by pure luck? Surely if we search long enough for working strategies we will end up finding one. Even in a walk forward approach that doesn't tell us anything about the strategy in itself. Some people talk about white's reality check but there are no consensus in that matter.", "question_score": 37, "question_tags": ["backtesting", "strategy"], "choices": {"A": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "B": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "C": "Strictly speaking, data snooping is not the same as in-sample vs out-of-sample model selection and testing, but has to deal with sequential or multiple tests of hypothesis based on the same data set. To quote Halbert White: Data snooping occurs when a given set of data is used more than once for purposes of inference or model selection. When such data reuse occurs, there is always the possibility that any satisfactory results obtained may simply be due to chance rather than to any merit inherent in the methody yielding the results. Let me provide an example. Suppose that you have...", "D": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/140/what-are-the-popular-methodologies-to-minimize-data-snooping"}
{"id": "finance_530", "domain": "finance", "question_title": "Digital Signal Processing in Trading", "question_body": "There is a concept of trading or observing the market with signal processing originally created by John Ehler . He wrote three books about it. Cybernetic Analysis for Stocks and Futures Rocket Science for Traders MESA and Trading Market Cycles There are number of indicators and mathematical models that are widely accepted and used by some trading software (even MetaStock), like MAMA, Hilbert Transform, Fisher Transform (as substitutes of FFT), Homodyne Discriminator, Hilbert Sine Wave, Instant Trendline etc. invented by John Ehler. But that is it. I have never heard of anybody other than John Ehler studying in this area. Do you think that it is worth learning digital signal processing? After all, each transaction is a signal and bar charts are somewhat filtered form of these signals. Does it make sense?", "question_score": 37, "question_tags": ["trading", "digital-signal-processing"], "choices": {"A": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "B": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "C": "I can think of an application in options pricing. I came across the following paper a long time ago but think it explains FT very eloquently as applied to pricing options under BS: http://maxmatsuda.com/Papers/2004/Matsuda%20Intro%20FT%20Pricing.pdf The fun starts on page 112 but it relies on the 1998 paper by Madan and Carr. What I like about the paper is that it gives a thorough introduction to FT and only when the groundwork is set it applies it to option pricing. Not a bad approach vs many other papers which make a lot of assumption and assume the reader can jump right...", "D": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/530/digital-signal-processing-in-trading"}
{"id": "finance_2079", "domain": "finance", "question_title": "Skew arbitrage: How can you realize the skewness of the underlying?", "question_body": "It's not clear to me how to realize skewness. In other words, how do you implement skew arbitrage? There seems to be no well-known recipe like in volatility arbitrage . Volatility arbitrage (or vol arb) is a type of statistical arbitrage implemented by trading a delta neutral portfolio of an option and its underlier. The objective is to take advantage of differences between the implied volatility and a forecast of future realized volatility of the option's underlier. My hypothetical skew arbitrage definition: Skew arbitrage is a type of statistical arbitrage implemented by trading a delta and volatility neutral portfolio. The objective is to take advantage of differences between the implied skew and a forecast of future realized skew of the option's underlier. Is it possible to make such a skew-arb portfolio in practice? If I have great confidence in my skew forecast but not in my volatility forecast, I am tempted to engage in this type arbitrage. But again, this is just a hypothetical version of skew arbitrage. If you know a correct and more practical version, you are welcome to correct me! The same question but in a different voice: In practice, a skew bet is implemented through vertical spread, i.e. buying and selling options of different strikes. How do options traders hedge / realize the edge of the spread they trade that is indifferent to the underlying volatility?", "question_score": 37, "question_tags": ["options", "volatility", "trading", "hedging", "option-strategies"], "choices": {"A": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "B": "Great question! I think the most useful starting point is Stock Return Characteristics, Skew Laws, and the Differential Pricing of Individual Equity Options by Bakshi, Kapadia and Madan (2003) . Their paper proposes a definition of model-free implied skewness (they originally called it risk-neutral skewness, but MFIS is more accurate), which they prove will have a P&L directly proportional to the realized skewness of the underlier. Subsequent papers (there are literally dozens) have thoroughly explored the properties of MFIS. In particular, Does Risk-Neutral Skewness Predict the Cross-Section of Equity Option Portfolio Returns? by Bali and Murray (2011) estimates the empirical...", "C": "For an option with price $C$ , the P $\\&$ L, with respect to changes of the underlying asset price $S$ and volatility $\\sigma$ , is given by \\begin{align*} P\\&L = \\delta \\Delta S + \\frac{1}{2}\\gamma (\\Delta S)^2 + \\nu \\Delta \\sigma, \\end{align*} where $\\delta$ , $\\gamma$ , and $\\nu$ are respectively the delta, gamma, and vega hedge ratios. Then it is clear the vega P $\\&$ L has exposure to the change of the implied volatility $\\sigma$ . Note that, for the gamma P $\\&$ L, \\begin{align*} \\frac{1}{2}\\gamma (\\Delta S)^2 = \\frac{1}{2}\\gamma S^2 \\frac{1}{\\Delta t}\\left(\\frac{\\Delta S}{S}\\right)^2\\Delta t, \\end{align*} where...", "D": "Being short gamma simply means that you are short options regardless of whether they are puts or calls. The most common type of investor that is willing to be short gamma is someone who sells options, also known as a premium collector. These investors commonly use strategies such as short puts, covered calls, iron condors, vertical credit spreads, and a few others. These strategies are typically referred to as income generation strategies. They offer the investor a return known in advance, in exchange for the risk of being short options. Frequently these types of income trades have have a probability..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2079/skew-arbitrage-how-can-you-realize-the-skewness-of-the-underlying"}
{"id": "finance_10359", "domain": "finance", "question_title": "Is there an intuitive explanation for the Feynman-Kac-Theorem?", "question_body": "The Feynman-Kac theorem states that for an Ito-process of the form $$dX_t = \\mu(t, X_t)dt + \\sigma(t, X_t)dW_t$$ there is a measurable function $g$ such that $$g_t(t,x) + g_x(t, x) \\mu(t,x) + \\frac{1}{2} g_{xx}(t,x)\\sigma(t,x)^2 = 0$$ with an appropriate boundary condition $h$: $g(T,x) = h(x)$. We also know that $g(t,x)$ is of the form $$g(t,x)=\\mathbb{E}\\left[h(X_T) \\big| X_t=x\\right].$$ This means that I can price an option with payoff function $h(x)$ at $T$ by solving the differential equation without regard to the stochastic process. Is there an intuitive explanation how it is possible to model the stochastic behaviour of the Ito-process by a differential equation, even though the differential equation does not have a stochastic component?", "question_score": 37, "question_tags": ["brownian-motion", "differential-equations"], "choices": {"A": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "B": "Martingales + Markovian Here is the motivation. Conditional expectations are martingales by the tower property of conditional expectations (an easy exercise to show). Suppose $r=0$, by the risk neutral pricing theorem $E^\\star\\left[h(X_T)\\bigg|\\mathscr{F}_t,\\,X_t=x\\right]$ is the price of any derivative security with $X$ as the underlying asset and payoff function $h$ assuming for the moment that the underlying security and the derivative itself pay no intermediate cashflows. In a Markovian setting, it must be the case that the price of the derivative is a measurable function of the current asset price and the time to maturity only, say a function $g(t, x)$....", "C": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and...", "D": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/10359/is-there-an-intuitive-explanation-for-the-feynman-kac-theorem"}
{"id": "finance_1937", "domain": "finance", "question_title": "How to identify technical analysis chart patterns algorithmically?", "question_body": "I'm working on a small application that will provide some charts and graphs to be used for technical analysis. I'm new to TA but I'm wondering if there is a way to algorithmically identify the formation of certain patterns. In most of the TA literature I've read the authors explain how to identify these patterns visually. Is there a way to algorithmically determine these patterns so that I could, for example, examine the prices in code and identify a possible Head and Shoulders pattern?", "question_score": 36, "question_tags": ["algorithm", "technicals", "indicator"], "choices": {"A": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "B": "I would offer the distinctions are i) pure statistical approach, ii) equilibrium based approach, and iii) empirical approach. The statistical approach includes data mining. Its techniques originate in statistics and machine learning. In its extreme there is no a priori theoretical structure imposed on asset returns. Factor structure might be identified thru Principal Components, for example. The goal here is to maximize predictive accuracy at the expense of intuition and explanatory power. This approach increasingly dominates at very short frequencies in modeling market microstructure, market making algorithms, volatility modeling, etc. However, even in high-frequency trading one can impose a factor...", "C": "As mentioned elsewhere on this site, Lo, Mamaysky, and Wang (2000) do exactly what you're talking about, namely algorithmic detection of head and shoulders patterns. Their definition: Head-and-shoulders (HS) and inverted head-and-shoulders (IHS) patterns are characterized by a sequence of five consecutive local extrema $E_1,...,E_5$ such that $$ HS \\equiv \\begin{cases} E_1 \\text{ is a maximum} \\\\ E_3 > E_1, E_3 > E_5 \\\\ E_1\\text{ and }E_5\\text{ are within 1.5 percent of their average} \\\\ E_2\\text{ and }E_4\\text{ are within 1.5 percent of their average,} \\end{cases} $$ $$ IHS \\equiv \\begin{cases} E_1\\text{ is a minimum} \\\\ E_3", "D": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1937/how-to-identify-technical-analysis-chart-patterns-algorithmically"}
{"id": "finance_4589", "domain": "finance", "question_title": "How to simulate stock prices with a Geometric Brownian Motion?", "question_body": "I want to simulate stock price paths with different stochastic processes. I started with the famous geometric brownian motion. I simulated the values with the following formula: $$R_i=\\frac{S_{i+1}-S_i}{S_i}=\\mu \\Delta t + \\sigma \\varphi \\sqrt{\\Delta t}$$ with: $\\mu= $ sample mean $\\sigma= $ sample volatility $\\Delta t = $ 1 (1 day) $\\varphi=$ normally distributed random number I used a short way of simulating: Simulate normally distributed random numbers with sample mean and sample standard deviation. Multiplicate this with the stock price, this gives the price increment. Calculate Sum of price increment and stock price and this gives the simulated stock price value. (This methodology can be found here ) So I thought I understood this, but now I found the following formula , which is also the geometric brownian motion: $$ S_t = S_0 \\exp\\left[\\left(\\mu - \\frac{\\sigma^2}{2}\\right) t + \\sigma W_t \\right] $$ I do not understand the difference? What does the second formula says in comparison to the first? Should I have taken the second one? How should I simulate with the second formula?", "question_score": 36, "question_tags": ["equities", "simulations", "stochastic-processes", "brownian-motion"], "choices": {"A": "I know that I have seen things like this in the past. Wasn't there something recently that used Twitter? Here are a few recent papers as examples, although I will be brutally honest that I don't know if they speak to your decent quality requirement: \"Trading Strategies to Exploit Blog and News Sentiment\" (Zhang, Skiena 2010) \"The Predictive Power of Financial Blogs\" (Frisbee 2010) \"An analysis of verbs in financial news articles and their impact on stock price\" (Schumaker 2010)", "B": "I recently read \"Modeling financial data with stable distributions\" (Nolan 2005) which gives a survey of this area and might be of interest (I believe it was contained in \"Handbook of Heavy Tailed Distributions in Finance\" ). Another more recent reference is \"Alpha-Stable Paradigm in Financial Markets\" (2008). I'm not aware of anything covering \"risk of fluctuations\" and this is still certainly not at the center of the field (i.e. most theory still includes some version of Gaussian or mixture of Gaussians). Would also be interested in other references.", "C": "The way you do it in the first place is a discretization of the Geometric Brownian Motion (GBM) process. This method is most useful when you want to compute the path between $S_0$ and $S_t$, i.e. you want to know all the intermediary points $S_i$ for $0 \\leq i \\leq t$. The second equation is a closed form solution for the GBM given $S_0$. A simple mathematical proof showed that, if you know the initial point $S_0$ (which is $a$ in your equation), then the value of the process at time $t$ is given by your equation (which contains $W_t$,...", "D": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/4589/how-to-simulate-stock-prices-with-a-geometric-brownian-motion"}
{"id": "finance_139", "domain": "finance", "question_title": "Trading a synthetic replication of the VIX index", "question_body": "One cannot directly buy and sell the VIX index. Theoretically, however, one could approximate the index by purchasing an at-the-money straddle on the SP500, then delta-hedging the straddle. Does anyone have experience with such a \"synthetic\" replication of the index? It might be very useful for betting on volatility or for spreads against the VIX futures (a sort of basis trade), but I can see potential problems if the replication is too inaccurate. (To anticipate your comments: I'm aware of the many VIX-related ETFs; but, no, I would not consider using them. I'm also aware that the VIX calculation uses other strikes beyond the ATM options; this proposed synthetic is admittedly an approximation.)", "question_score": 35, "question_tags": ["vix", "delta-neutral"], "choices": {"A": "A synthetic model for the VIX would be quite useful. I just mention this since it has been covered elsewhere in the past, although I don't think that it's a real solution to your problem (for a number of reasons). Several blogs posted on the \"William's VIX Fix\" (WVF) in the past: marketsci , trading the odds , mindmoneymarkets . The WVF is intended to be a synthetic VIX calculation, derived by Larry Williams (see the original article here ), and is represented by the following formula: $wvf = \\frac{Highest(Close, 22) - Low}{Highest(Close, 22)} * 100$ In R, this can...", "B": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "C": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "D": "I haven't read Natenberg but it of course depends on your side in the trade: Are you a market maker or a risk taker? So do you live on the spread (first) or are trying to make money based on e.g. forecasts on direction (second). This is the great divide in QuantFinance! Only in the first case will all your option trades be delta neutral. There is a nice short paper which elaborates on both concepts (it calls the first one Q and the second P ): Meucci: 'P' Versus 'Q': Differences and Commonalities between the Two Areas of Quantitative..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/139/trading-a-synthetic-replication-of-the-vix-index"}
{"id": "finance_2360", "domain": "finance", "question_title": "What exactly is meant by "microstructure noise"?", "question_body": "I see that term tossed around a lot, in articles relating to HFT, and ultra high frequency data. It says at higher frequencies, smaller intervals, microstructure noise is very dominant. What is this microstructure noise that they refer to?", "question_score": 35, "question_tags": ["volatility", "statistics", "high-frequency", "market-microstructure", "high-frequency-estimators"], "choices": {"A": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "B": "Volatility is mean reverting if the underlying security doesn't drop to zero. If the security has some underlying \"value\" then its price is co-integrated with that \"value\". The volatility is the uncertainty of that price as it tracks the security's \"value\". Edit 12/03/2011 ================================================= @pteetor, I may have missed something, but the question was \" Why is volatility mean-reverting?\". I realize that the standard answer is that the VIX (I'm assuming he's asking about the VIX) is related to the historical volatility of the S&P. A simple version of that relationship provides a reasonable R^2 (see Fig. 1). It relates...", "C": "The term has a different meaning to different people. to econometricians, microstructure noise is a disturbance that makes high frequency estimates of some parameters (e.g. realized volatility) very unstable. Generally this strand of the literature professes agnosticism as to the its origin; to market microstructure researchers, microstructure noise is a deviation from fundamental value that is induced by the characteristics of the market under consideration, e.g. bid-ask bounce, the discreteness of price change, latency, and asymmetric information of traders. The last example is frequently cited but I don't think it is accurate. Asymmetric information does not have to be a...", "D": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2360/what-exactly-is-meant-by-microstructure-noise"}
{"id": "finance_6988", "domain": "finance", "question_title": "How do we use option price models (like Black-Scholes Model) to make money in practice?", "question_body": "In quantitative finance, we know we have a lot of option price models such as geometric Brownian motion model (Black-Scholes models), stochastic volatility model (Heston), jump diffusion models and so on, my question is how can we use these models to make money in practice? My comments: Because we can read option price from the market, by these models (Black-Scholes), we can get the implied volatility, then we may use this implied volatility to compute other exotic option price, then we can make money by selling/buying this exotic option as a market maker, is this the only way to make money? For stocks, we know that if we have a better model to predict future stock prices, then we can make money, but for option, it seems that we didn't use these models to predict the future option prices? so how can we make money with these models?", "question_score": 35, "question_tags": ["option-pricing", "black-scholes", "models"], "choices": {"A": "In order to answer your question (for you) you would need something to compare to . You would need numbers to know if it is slower/faster, how much, and if it will impact your system overall. Also knowing your performance goals could narrow down the options. My advice is to take a look at your overall architecture of the sytem you have or intend to build. To just look at QuickFIX is rather meaningless without the whole chain involved in processing information and reacting to it . As an example, say QuickFIX is 100 times faster than some part (in...", "B": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a...", "C": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "D": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/6988/how-do-we-use-option-price-models-like-black-scholes-model-to-make-money-in-pr"}
{"id": "finance_55239", "domain": "finance", "question_title": "Explaining the Risk Neutral Measure", "question_body": "What is the Risk Neutral Measure? I don't believe this has been answered on the internet well and with all the parts connecting. So: What is the risk neutral measure/pricing? Why do we need it? How we calculate the risk neutral measure or probabilities in practice? What connection has risk neutral pricing to the drift of a SDE? Does this help with 3)?", "question_score": 35, "question_tags": ["option-pricing", "stochastic-processes", "risk-neutral-measure", "pricing", "martingale"], "choices": {"A": "Intro: Great answer given by Kevin. I would like to contribute an additional perspective. My experience with and my understanding of the Risk Neutral measure is entirely based on \"no arbitrage\" and \"replication / hedging\" arguments. The way I would like to explain this view is via the following three-step construction : (i) First, I want to build the intuition with a one-period discrete model: only a single stock and a risk-free account, no derivatives . The aim is to show that even without trying to price derivatives, one can create a mathematical object called a \"risk-neutral probability measure\", just...", "B": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "C": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "D": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/55239/explaining-the-risk-neutral-measure"}
{"id": "finance_14567", "domain": "finance", "question_title": "What is the Swap Curve?", "question_body": "What is the so-called Swap Curve, and how does it relate to the Zero Curve (or spot yield curve)? Does it only refer to a curve of swap rates versus maturities found in the market? Or is it a swap equivalent of a spot-yield curve constructed from bootstrapping a bond yield curve? The context of this question is set against a backdrop of a plethora of terminology (that seems to be used interchangeably). I am looking into how the so-called Zero Curve (or spot yield curve) is constructed in order to discount various IR derivatives (including swaps) when pricing them.", "question_score": 34, "question_tags": ["yield-curve", "swaps", "interest-rate-swap"], "choices": {"A": "It's an interesting question. I particularly agree with the $\\mathbb{Q}-\\mathbb{P}$ dichotomy mentioned by many. I would add to the other answers that, come to think of it, the Black-Scholes postulated Geometric Brownian Motion could be interpreted as an AR(1) process on the logarithm of the stock price as you discretise the SDE from which it is a solution, which is exactly what you do when running Monte-Carlo simulations (same thing for the Ornstein-Uhlenbeck process as explained here and noted by @Richard). Actually, when taking the continuous-time limit, many more econometric models can be shown to correspond to stochastic processes frequently...", "B": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "C": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "D": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/14567/what-is-the-swap-curve"}
{"id": "finance_148", "domain": "finance", "question_title": "What is the role of stochastic calculus in day-to-day trading?", "question_body": "I work with practical, day-to-day trading: just making money. One of my small clients recently hired a smart, new MFE. We discussed potential trading strategies for a long time. Finally, he expressed surprise that I never mentioned (much less used) stochastic calculus, which he spent many long hours studying in his MFE program. I use the products of stochastic calculus (e.g., the Black-Scholes equation) but not the calculus itself. Now I am wondering, does stochastic calculus play a role in day-to-day trading strategies? Am I under-utilizing a potentially valuable tool? If this client was a Wall Street investment bank that was making markets in complicated derivatives, I'm sure their research department would use stochastic calculus for modeling. But they're not, so I'm not sure how we would use stochastic calculus. ( Full disclosure: I have Masters degrees but not a PhD. I'm an applied mathematician, not a theoretician.)", "question_score": 33, "question_tags": ["differential-equations", "stochastic-calculus"], "choices": {"A": "Martingales + Markovian Here is the motivation. Conditional expectations are martingales by the tower property of conditional expectations (an easy exercise to show). Suppose $r=0$, by the risk neutral pricing theorem $E^\\star\\left[h(X_T)\\bigg|\\mathscr{F}_t,\\,X_t=x\\right]$ is the price of any derivative security with $X$ as the underlying asset and payoff function $h$ assuming for the moment that the underlying security and the derivative itself pay no intermediate cashflows. In a Markovian setting, it must be the case that the price of the derivative is a measurable function of the current asset price and the time to maturity only, say a function $g(t, x)$....", "B": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "C": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "D": "This is pure speculation: MFE's are really tailored toward valuation models (how can we develop a model to price x swap, etc.). You don't entirely have to worry about those details in order to trade them: you're just quoted a price based on these models. But if you go in-house at a bank and are working as a product quant (structured products, etc.), then you really need to worry about these things. Alternatively, it could be relevant to a trading strategy if you think that the current model is mispricing things and there's an arbitrage opportunity. This is why banks..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/148/what-is-the-role-of-stochastic-calculus-in-day-to-day-trading"}
{"id": "finance_613", "domain": "finance", "question_title": "What is the best data structure/implementation for representing a time series?", "question_body": "I was wondering what is best practice for representing elements in a time series, especially with large amounts of data. The focus/context is in a back testing engine and comparing multiple series. It seems there are two options: 1) Using an integer index, or 2) Using a date-based index At the moment I am using dates, but this impacts on performance & memory usage in that I am using a hash table rather than an array, and it requires some overhead in iteration (either forward or backwards) as I have to determine the next/previous valid date before I can access it. However, it does let me aggregate data on the fly (e.g. building the ohlc for the previous week when looking at daily bars) and most importantly for me allows me to compare different series with certainty I am looking at the same date/time. If I am looking at an equity issue relative to a broader index, and say the broader index is missing a few bars for whatever reason, using an integer indexed array would mean I'm looking at future data for the broad index vs present data for the given security. I don't see how you could handle these situations unless you're using date/times. Using integer indexes would be a lot easier code wise, so I was just wondering what others are doing or if there is best practice with this.", "question_score": 33, "question_tags": ["data", "time-series", "market-data"], "choices": {"A": "Representing time series (esp. tick data) using elaborate data structures may be not the best idea. You may want to try to use two arrays of the same length to store your time series. The first array stores values (e.g. price) and the second array stores time. Note that the second series is monotonically increasing (or at least non-decreasing), i.e. it's sorted. This property enables you to search it using the binary search algorithm. Once you get an index of a time of interest in the second array you also have the index of the relevant entry in the first...", "B": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "C": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "D": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/613/what-is-the-best-data-structure-implementation-for-representing-a-time-series"}
{"id": "finance_942", "domain": "finance", "question_title": "Any known bugs with Yahoo Finance adjusted close data ?", "question_body": "Yahoo Finance allows you to download tables of their daily historical stock price data. The data includes an adjusted closing price that I thought I might use to calculate daily log returns as a first step to other kinds of analyses. To calculate the adj. close you need to know all the splits and dividends, and ex-div and ex-split dates. If someone gets this wrong it should create some anomalous returns on the false vs. true ex dates. Has anyone seen any major problems in the adj. closing price data on Yahoo Finance?", "question_score": 33, "question_tags": ["data", "equities", "adjustments", "yahoo"], "choices": {"A": "Yahoo rounds the adjusted price to 2 decimals even though dividend amounts often have 3 decimal places. Since they apply the adjustment formula to adjusted prices, if you go far enough back in time, the value they give for Adjusted Price will be different than it would be if there were no rounding. edit: For example, for C (Citigroup), on January 2, 1990, Yahoo gives a close value of 29.37 and an Adjusted value of 1.50. Using the dividend data that Yahoo supplies, if they didn't round to cents on every adjustment, the adjusted value would be 1.677.", "B": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "From my experience, EODData is pretty much that you get what you pay for. Its not a very sophisticated product. They email you the files you subscribe to, and thats that. I have had an issue before of where the emails didn't go through anymore and I never heard anything from them. On Quality, I can't make a claim on its accuracy. It seems good. I find issue with three things about the data: There is no way to signal an exchange change It doesn't give you an easy way to grab the symbol info [Names, etc] If there is..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/942/any-known-bugs-with-yahoo-finance-adjusted-close-data"}
{"id": "finance_219", "domain": "finance", "question_title": "What is the intuition behind cointegration?", "question_body": "What is the intuition behind cointegration? What does the Dickey-Fuller test do to test for it? Ideally, a non-technical explanation would be appreciated. Say you need to explain it to an investor and justify why your pairs trading strategy should make him rich!", "question_score": 32, "question_tags": ["time-series", "statistics", "cointegration", "intuition"], "choices": {"A": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "B": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a...", "C": "It's an interesting question. I particularly agree with the $\\mathbb{Q}-\\mathbb{P}$ dichotomy mentioned by many. I would add to the other answers that, come to think of it, the Black-Scholes postulated Geometric Brownian Motion could be interpreted as an AR(1) process on the logarithm of the stock price as you discretise the SDE from which it is a solution, which is exactly what you do when running Monte-Carlo simulations (same thing for the Ornstein-Uhlenbeck process as explained here and noted by @Richard). Actually, when taking the continuous-time limit, many more econometric models can be shown to correspond to stochastic processes frequently...", "D": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/219/what-is-the-intuition-behind-cointegration"}
{"id": "finance_2707", "domain": "finance", "question_title": "How do you mix quantitative asset allocation with qualitative views?", "question_body": "Usually in asset allocation you have a quantitative approach (which can be from example mean-variance), but you (or you and your firm) also have a more qualitative approach given market-conditions, economic outlooks, or tactical indicators. Hence, you will eventually come up with 2 allocations, the ones strictly dictated by the numbers $w^*$ which is the result of your quantitative algorithm and the one you have in mind from your personal expectations $\\bar{w}$. What are common the ways $f$ to mix them together such that $w=f(w^*,\\bar{w})$ is your \"final\" allocation?", "question_score": 32, "question_tags": ["asset-allocation"], "choices": {"A": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "B": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "C": "I think you're overlooking a third explanation: Nobody that found a successful technique to generate alpha has published it. I can think of the following causes: If you're an academic, why share your brilliant idea? These techniques require a lot of data and financial data can be expensive, researches that work at firms that have access to this data don't share their findings with the public. Academics did find a lot of signals already the old fashioned way. Despite this, fancy techniques such as AAD and Reinforcement Learning are discussed publicly. These methods don't generate any alpha however.", "D": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2707/how-do-you-mix-quantitative-asset-allocation-with-qualitative-views"}
{"id": "finance_5981", "domain": "finance", "question_title": "What are the advantages/disadvantages of these approaches to deal with volatility surface?", "question_body": "I would like to know if someone could provide a summarized view of the advantages and disadvantages of the approaches on the volatility surface issues, such as: Local vol Stochastic Vol (Heston/SVI) Parametrization (Carr and Wu approach)", "question_score": 32, "question_tags": ["volatility"], "choices": {"A": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "B": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "C": "Your questions about contango in VIX futures have close analogies in options too. The Black & Scholes model suggests that all time frames and all strikes should have the same implied volatility, but they don't. I think one of the reasons is that the B&S model assumes that stock returns are distributed in a normal (gaussian) distribution, but the actual returns don't match a gaussian distribution all that well. For example the actual occurrence of big crashes / gains is much more likely than a normal distribution would predict. Since crashes do occur people are willing to pay what the...", "D": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/5981/what-are-the-advantages-disadvantages-of-these-approaches-to-deal-with-volatilit"}
{"id": "finance_44", "domain": "finance", "question_title": "What methods do you use to improve expected return estimates when constructing a portfolio in a mean-variance framework?", "question_body": "One of the main problems when trying to apply mean-variance portfolio optimization in practice is its high input sensitivity. As can be seen in ( Chopra , 1993) using historical values to estimate returns expected in the future is a no-go, as the whole process tends to become error maximization rather than portfolio optimization . The primary emphasis should be on obtaining superior estimates of means , followed by good estimates of variances. In that case, what techniques do you use to improve those estimates ? Numerous methods can be found in the literature, but I'm interested in what's more widely adopted from a practical standpoint . Are there some popular approaches being used in the industry other than Black-Litterman model? Reference: Chopra, V. K. & Ziemba, W. T. The Effect of Errors in Means, Variances, and Covariances on Optimal Portfolio Choice . Journal of Portfolio Management , 19: 6-11, 1993.", "question_score": 31, "question_tags": ["modern-portfolio-theory", "mean-variance", "expected-return", "estimation"], "choices": {"A": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a...", "B": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "C": "Hey, it's early days yet. After all it is still called MODERN portfolio theory. I think there are two main issues and they are both really cultural: 1) specifying alphas 2) wild results Alphas I agree with Gappy that alphas are the key thing you need to have effectiveness (unless you are doing minimum variance). Having a vector of expected returns is quite a natural thing for quant managers. But it is something foreign to fundamental managers. They have to map their views into a number for each asseet in the universe. That is not necessarily an easy task, and...", "D": "Short of having a 'reasonable' predictive model for expected returns and the covariance matrix, there are a couple lines of attack. Shrinkage estimators (via Bayesian inference or Stein-class of estimators) Robust portfolio optimization Michaud's Resampled Efficient Frontier Imposing norm constraints on portfolio weights Naively, shrinkage methods 'shrink' (of course,no?) your estimates (arrived at using historical data), toward some global mean or some target. Within the mean-variance framework, you can use the shrinkage estimators, for both, the expected returns vector, as well as the covariance matrix. Jorion introduced application of a 'Bayes-Stein estimator' to portfolio analysis. Bradley & Efron have a..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/44/what-methods-do-you-use-to-improve-expected-return-estimates-when-constructing-a"}
{"id": "finance_332", "domain": "finance", "question_title": "Any research on how natural language processing can be used to forecast stocks?", "question_body": "Is there any published research of decent quality linking news or unstructured information to asset returns? I know that Thomson Reuters offers its Machine Readable news (MRN), so somebody must use it. But I can't find much in the public domain.", "question_score": 31, "question_tags": ["equities", "forecasting", "research", "prediction", "nlp"], "choices": {"A": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "B": "A general model (with continuous paths) can be written $$ \\frac{dS_t}{S_t} = r_t dt + \\sigma_t dW_t^S $$ where the short rate $r_t$ and spot volatility $\\sigma_t$ are stochastic processes. In the Black-Scholes model both $r$ and $\\sigma$ are deterministic functions of time (even constant in the original model). This produces a flat smile for any expiry $T$. And we have the closed form formula for option prices $$ C(t,S;T,K) = BS(S,T-t,K;\\Sigma(T,K)) $$ where $BS$ is the BS formula and $\\Sigma(T,K) = \\sqrt{\\frac{1}{T-t}\\int_t^T \\sigma(s)^2 ds}$. This is not consistent with the smile observed on the market. In order to match...", "C": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "D": "I know that I have seen things like this in the past. Wasn't there something recently that used Twitter? Here are a few recent papers as examples, although I will be brutally honest that I don't know if they speak to your decent quality requirement: \"Trading Strategies to Exploit Blog and News Sentiment\" (Zhang, Skiena 2010) \"The Predictive Power of Financial Blogs\" (Frisbee 2010) \"An analysis of verbs in financial news articles and their impact on stock price\" (Schumaker 2010)"}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/332/any-research-on-how-natural-language-processing-can-be-used-to-forecast-stocks"}
{"id": "finance_9911", "domain": "finance", "question_title": "Book on market microstructure", "question_body": "Can I get some recommendations for a book on market microstructure? I'm not looking for some author's questionable methods for trading, I'm just looking for a book that provides me with facts about how order books, closing auctions, order execution, etc. really works. I'm also NOT looking for the type of depth that a HFT would be interested in. I know that whole books can be written about the various plumbing of a particular exchange. I'm simply looking for a general overview of how exchanges work.", "question_score": 31, "question_tags": ["market-microstructure", "books"], "choices": {"A": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident...", "B": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "C": "I've not yet read it, but Lehalle's recent book is bound to be a goldmine of good micro-structure bits and pieces. Market Microstructure in Practice EDIT: I'm reading the book now, so far it's quite good.", "D": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/9911/book-on-market-microstructure"}
{"id": "finance_955", "domain": "finance", "question_title": "Separating the wheat from the chaff: What quant methods separate skillful managers from lucky ones?", "question_body": "Fund managers are acting in a highly stochastic environment. What methods do you know to systematically separate skillful fund managers from those that were just lucky? Every idea, reference, paper is welcome! Thank you!", "question_score": 30, "question_tags": ["performance-evaluation"], "choices": {"A": "Larry Harris has a chapter on performance evaluation in Trading and Exchanges . He states that over a long period of time, a skilled asset manager will consistently have excess returns whereas a lucky one will be expected to have random and unpredictable returns. Thus, we start with the portfolio's market-adjusted return standard deviation: \\begin{equation} \\sigma_{adj} = \\sqrt{\\sigma^2_{port} + \\sigma^2_{mk} - 2\\rho\\sigma_{port}\\sigma_{mk}} \\end{equation} where $\\rho$ is the correlation between the market and portfolio returns. For a sample size $n$ (generally number of years), the average excess returns, and the adjusted standard deviation from above, we have a t-statistic : \\begin{equation}...", "B": "I think you're overlooking a third explanation: Nobody that found a successful technique to generate alpha has published it. I can think of the following causes: If you're an academic, why share your brilliant idea? These techniques require a lot of data and financial data can be expensive, researches that work at firms that have access to this data don't share their findings with the public. Academics did find a lot of signals already the old fashioned way. Despite this, fancy techniques such as AAD and Reinforcement Learning are discussed publicly. These methods don't generate any alpha however.", "C": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "D": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/955/separating-the-wheat-from-the-chaff-what-quant-methods-separate-skillful-manage"}
{"id": "finance_1685", "domain": "finance", "question_title": "Why do high frequency traders use rapidly cancelled limit orders?", "question_body": "In reading about the various practices and strategies of high frequency traders, one of the most mysterious to me is \"fleeting orders,\" or orders that are cancelled almost immediately after they are sent (see Hasbrouck and Saar (2011) ). Why do HFTs use these orders? Some of those trying to explain the practice claim it gives HFTs an informational advantage. How? What information do they get and how do they use it? Update I am hoping for someone with actual experience in HFT to answer and verify some of the hypotheses laid out by academics. In particular, one hypothesis is that rapidly cancelled limit orders bring forth market orders on the other side, which are then executed at a less favorable price also placed by the HFT. In other words, HFTs are gaming the system to exploit sub-optimal behavior by slower traders. Is there any evidence of this still occurring, now that the practice of fleeting orders is widespread and well known? This explanation would also imply that it is relatively simple to avoid being taken advantage of, thus weakening the policy implications. Is there some reason that slower traders prefer sending market orders only after seeing a limit order meeting their price target?", "question_score": 30, "question_tags": ["high-frequency", "market-making"], "choices": {"A": "The lead paper in the January 2011 Journal of Finance ( Hendershott, Jones, and Menkveld ) addresses algorithmic trading (AT). In short, they find that AT improves liquidity as measured by bid-offer spreads. Taking the econometrics as correct (it is in the Journal of Finance) the next question is if bid-offer spreads are a sufficient statistic for measuring liquidity (or any other benefits). It is a difficult question to answer because, given current market structure, AT may improve liquidity (as measured by bid-offer spreads), but without data on other market structures, it is hard to say that we wouldn't better...", "B": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "All HFTs are event driven. In the most basic sense, they have some model that is a function of order book events. For every order book event the model calculates some micro price that is the HFTs perceived fair value. This is often a function of the current bid, ask, depth, last n trade prices, inventory, etc. Given the most up to date view of fair value, the HFT will be adjust orders in the market. As you can imagine, the rate of events for order book data is very high. This results in a very high scratch rate (cancel..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1685/why-do-high-frequency-traders-use-rapidly-cancelled-limit-orders"}
{"id": "finance_7377", "domain": "finance", "question_title": "Applications of Fourier theory in trading", "question_body": "What are fashionable applications of Fourier analysis in trading? I have heard vague ideas of applications in High Frequency Trading but can somebody provide an example, maybe a reference? Just for clarification: The approach to split up a stock price in its cosines and to apply this for forecasts or anything similar seems theoretically not justified as we can not assume the stock price to be periodic (outside of the period of observation). So I don't really mean such applications. Put differently: are there useful, theoretically valid applications of Fourier theory in trading? I am curious for any comments, thank you! EDIT: I am aware of (theoretically $100\\%$ valid) applications in option pricing and calculation of risk measures in the context of Lévy processes (see e.g. here p.11 and following and references therein). This is well established, I guess. What I mean are applications in time series analysis. Sorry for any confusions.", "question_score": 30, "question_tags": ["trading", "high-frequency"], "choices": {"A": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "B": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "C": "I can think of an application in options pricing. I came across the following paper a long time ago but think it explains FT very eloquently as applied to pricing options under BS: http://maxmatsuda.com/Papers/2004/Matsuda%20Intro%20FT%20Pricing.pdf The fun starts on page 112 but it relies on the 1998 paper by Madan and Carr. What I like about the paper is that it gives a thorough introduction to FT and only when the groundwork is set it applies it to option pricing. Not a bad approach vs many other papers which make a lot of assumption and assume the reader can jump right...", "D": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/7377/applications-of-fourier-theory-in-trading"}
{"id": "finance_7402", "domain": "finance", "question_title": "how to derive yield curve from interest rate swap?", "question_body": "According to some textbooks, to derive the yield curve, quote overnight to 1 week: rates from interbank money market deposit, 1 month to 1 year: LIBOR; 1 year to 7 years: Interest Rate Swap; 7 years above: government bond. I'm a bit lost here: how can an IRS rate be used to derive yield curve? Yield rate is the discount rate, if $ yield (5 years) = 4.1 \\% $ , it means the NPV of 1 dollar 5 years later is $ NPV ( 1 dollar, 5 years) = 1/[(1+4.1\\%)^5] = 0.818 $. While interest rate swap is a contract among to legs. Assume a 5 years' IRS contract is leg A pays fixed rate to B @ 8.5%, while A receives floating rate @ LIBOR +1.5% leg B pays floating rate to A @ LIBOR +1.5%, B receives fixed rate@ 8.5%. , how could this swap contract help deriving the 5 years' yield rate?", "question_score": 30, "question_tags": ["interest-rates", "swaps", "yield-curve", "interest-rate-swap", "irs"], "choices": {"A": "The standard story (also told by @vonjd) is of \"The Drunk and Her Dog\". This is based on \"A Drunk and Her Dog: An Illustration of Cointegration and Error Correction\" (1994). The story is itself based on the standard illustration for a random walk known as the \"drunkard's walk\". The Dickey-Fuller test is used to check for a unit root . It can be used as part of the general Engle-Granger two-step method (although it isn't the only option). In this case, while the two assets themselves are not stationary, you are able to test if the residuals between a...", "B": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a...", "C": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "D": "You should take a look at the example from Hull's book. Assume that the 6-month, 12-month, 18-month zero rates are 4%, 4.5%, and 4.8%, respectively. Suppose we know that the 2-year swap rate is 5%, which implies that a 2-year bond with a semiannual coupon of 5% per annum sells for par: $$2.5 e^{-0.04 \\bullet 0.5} + 2.5 e^{-0.045 \\bullet 1.0} + 2.5 e^{-0.048 \\bullet 1.5} + 102.5 e^{-2 \\bullet R} = 100 \\; . $$ Solving for $R$ above gives a 2-year zero rate $R$ of 4.953%. We can keep going to compute the 3-year zero rates, etc."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/7402/how-to-derive-yield-curve-from-interest-rate-swap"}
{"id": "finance_43", "domain": "finance", "question_title": "Is there a standard model for market impact?", "question_body": "Is there a standard model for market impact? I am interested in the case of high-volume equities sold in the US, during market hours, but would be interested in any pointers.", "question_score": 29, "question_tags": ["market-impact", "models"], "choices": {"A": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we...", "B": "There is a family of models that is so commonly used among practitioners that it can be almost regarded as standard. For a survey, check out Rob Almgren's entry in the Encyclopedia of Quantitative Finance. Check out also Barra, Axioma and Northfield's handbooks. In general, the impact term per unit traded currency is of the form $$MI \\propto \\sigma_n \\cdot \\text{(participation rate)}^\\beta$$ where the exponent is somewhere between 1/2 and 1, depending on the model being used, and the participation rate is the percentage of total volume of the trade, during the trading interval itself. When including the total MI...", "C": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident...", "D": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/43/is-there-a-standard-model-for-market-impact"}
{"id": "finance_84", "domain": "finance", "question_title": "Transformation from the Black-Scholes differential equation to the diffusion equation - and back", "question_body": "I know the derivation of the Black-Scholes differential equation and I understand (most of) the solution of the diffusion equation. What I am missing is the transformation from the Black-Scholes differential equation to the diffusion equation (with all the conditions) and back to the original problem. All the transformations I have seen so far are not very clear or technically demanding (at least by my standards). My question: Could you provide me references for a very easily understood, step-by-step solution?", "question_score": 29, "question_tags": ["black-scholes", "differential-equations"], "choices": {"A": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we...", "B": "Martingales + Markovian Here is the motivation. Conditional expectations are martingales by the tower property of conditional expectations (an easy exercise to show). Suppose $r=0$, by the risk neutral pricing theorem $E^\\star\\left[h(X_T)\\bigg|\\mathscr{F}_t,\\,X_t=x\\right]$ is the price of any derivative security with $X$ as the underlying asset and payoff function $h$ assuming for the moment that the underlying security and the derivative itself pay no intermediate cashflows. In a Markovian setting, it must be the case that the price of the derivative is a measurable function of the current asset price and the time to maturity only, say a function $g(t, x)$....", "C": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "D": "It's an interesting question. I particularly agree with the $\\mathbb{Q}-\\mathbb{P}$ dichotomy mentioned by many. I would add to the other answers that, come to think of it, the Black-Scholes postulated Geometric Brownian Motion could be interpreted as an AR(1) process on the logarithm of the stock price as you discretise the SDE from which it is a solution, which is exactly what you do when running Monte-Carlo simulations (same thing for the Ornstein-Uhlenbeck process as explained here and noted by @Richard). Actually, when taking the continuous-time limit, many more econometric models can be shown to correspond to stochastic processes frequently..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/84/transformation-from-the-black-scholes-differential-equation-to-the-diffusion-equ"}
{"id": "finance_1004", "domain": "finance", "question_title": "How are cryptography and speech recognition technology applied to forecasting financial markets?", "question_body": "One of the answers to my previous question regarding the strategy of Renaissance Technologies , there was a reference to The Quants: How a New Breed of Math Whizzes Conquered Wall Street and Nearly Destroyed It . After doing some browsing in the book I found that it states that Renaissance Technologies obviously very successfully employs cryptography and speech recognition technology for forecasting financial time series. Do you know of any good papers (or other references) where the use of either of these technologies in connection with finance is shown?", "question_score": 29, "question_tags": ["quant-trading-strategies", "research", "forecasting", "machine-learning"], "choices": {"A": "By \"cryptography\" you mean information theory. Information theory is useful for portfolio optimization and for optimally allocating capital between trading strategies (a problem which is not well addressed by other theoretical frameworks.) See: --- J. L. Kelly, Jr., \"A New Interpretation of Information Rate,\" Bell System Technical Journal, Vol. 35, July 1956, pp. 917-26 --- E. T. Jaynes, Probability Theory: The Logic of Science http://amzn.to/dtcySD --- http://en.wikipedia.org/wiki/Gambling_and_information_theory http://en.wikipedia.org/wiki/Kelly_criterion In the simple case, you would use \"The Kelly Rule\". More complicated information theory based strategies for allocating capital between trading strategies take into account correlations between the performance of trading strategies...", "B": "Nick Higham's specialty is algorithms to find the nearest correlation matrix. His older work involved increased performance (in order-of-convergence terms) of techniques that successively projected a nearly-positive-semi-definite matrix onto the positive semidefinite space. Perhaps even more interesting, from the practitioner point of view, is his extension to the case of correlation matrices with factor model structures. The best place to look for this work is probably the PhD thesis paper by his doctoral student Ruediger Borsdorf. Higham's blog entry covers his work up to 2013 pretty well.", "C": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a...", "D": "I think you're overlooking a third explanation: Nobody that found a successful technique to generate alpha has published it. I can think of the following causes: If you're an academic, why share your brilliant idea? These techniques require a lot of data and financial data can be expensive, researches that work at firms that have access to this data don't share their findings with the public. Academics did find a lot of signals already the old fashioned way. Despite this, fancy techniques such as AAD and Reinforcement Learning are discussed publicly. These methods don't generate any alpha however."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1004/how-are-cryptography-and-speech-recognition-technology-applied-to-forecasting-fi"}
{"id": "finance_2076", "domain": "finance", "question_title": "How to interpret the eigenmatrix from a Johansen cointegration test?", "question_body": "I ran a Johansen cointegration test on 3 instruments, A B and C. The results that I got are: R 36.7 18.9 21.1 25.8 r=1 --> 8.4 12.29 14.26 18.52 r=2 --> 0.21 2.7 3.8 6.6 EigenValues EigenMatrix 0.03 --> 0.25 | 0.512 |-0.79 0.007 --> -0.96 | -0.618 | 0.14 0.00017 --> 0.05 | 0.59 | 0.59 My question is how I interpret these results? How do I know there is a cointegration for the these instruments. How to build a portfolio using the eigen vector? Which eigen vector should I choose to build my portfolio?", "question_score": 29, "question_tags": ["statistics", "cointegration"], "choices": {"A": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and...", "B": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "C": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters....", "D": "From remote memory, The first question is Yes/No question. Is there any stationary, i.e. I(0), time series for different levels of combination r? This question is answered by your first table. For example, if [r=2]'s test stat is say 7 while the critical value of 99% confidence is 6.6 like your example, then I have over 99% confidence to say that all instruments A, B, and C are stationary by themselves. You don't even need to build a co-integrated portfolio/combination. They are ready for mean-reversion strategy already. Obviously, in your example, your [r=2] stat is way much lower than even..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2076/how-to-interpret-the-eigenmatrix-from-a-johansen-cointegration-test"}
{"id": "finance_61760", "domain": "finance", "question_title": "Why are there no papers about stock prediction with machine learning in leading financial journals?", "question_body": "I'm writing my master's thesis about stock price prediction using machine learning methods. During my literature review, I noticed that a lot of research produced on this topic is of poor quality, published in non-finance related journals or unpublished/peer reviewed alltogether. There is no paper to be found in leading journals like journal of finance or journal of financial economics on the topic. I'm curious as to why this is the case. Did the academic world move on, and simply accept that markets are generally efficient a long time ago? Or are the leading journals overlooking a key technique that could effectively forecast stock price?", "question_score": 29, "question_tags": ["machine-learning", "market-efficiency"], "choices": {"A": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "B": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "I think you're overlooking a third explanation: Nobody that found a successful technique to generate alpha has published it. I can think of the following causes: If you're an academic, why share your brilliant idea? These techniques require a lot of data and financial data can be expensive, researches that work at firms that have access to this data don't share their findings with the public. Academics did find a lot of signals already the old fashioned way. Despite this, fancy techniques such as AAD and Reinforcement Learning are discussed publicly. These methods don't generate any alpha however."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/61760/why-are-there-no-papers-about-stock-prediction-with-machine-learning-in-leading"}
{"id": "finance_352", "domain": "finance", "question_title": "Volatility pumping in practice", "question_body": "The fascinating thing about volatility pumping (or optimal growth portfolio , see e.g. here ) is that here volatility is not the same as risk, rather it represents opportunity. Additionally it is a generic mechanical strategy that is independent of asset classes. My question: Do you know examples where volatility pumping is actually implemented? What are the results? What are the pitfalls?", "question_score": 28, "question_tags": ["volatility", "trading", "kelly-criterion"], "choices": {"A": "The optimal growth portfolio is obtained by applying the Kelly criterion which is one of the pillars of the sound risk management. Ed Thorp's weekend forays to Las Vegas to play blackjack were one of the first historically documented cases of successful practical implementation of the Kelly strategy. Since then this method and its modifications have been systematically used by Thorp himself and other hedge fund managers as an important risk control tool.", "B": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "C": "Great question! I think the most useful starting point is Stock Return Characteristics, Skew Laws, and the Differential Pricing of Individual Equity Options by Bakshi, Kapadia and Madan (2003) . Their paper proposes a definition of model-free implied skewness (they originally called it risk-neutral skewness, but MFIS is more accurate), which they prove will have a P&L directly proportional to the realized skewness of the underlier. Subsequent papers (there are literally dozens) have thoroughly explored the properties of MFIS. In particular, Does Risk-Neutral Skewness Predict the Cross-Section of Equity Option Portfolio Returns? by Bali and Murray (2011) estimates the empirical...", "D": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/352/volatility-pumping-in-practice"}
{"id": "finance_998", "domain": "finance", "question_title": "Strategy of Renaissance Technologies Medallion fund: Holy Grail or next Madoff?", "question_body": "Renaissance Technologies Medallion fund is one of the most successful hedge funds - ever! Yet it is very secretive. Do you have information on the strategy used that is not yet mentioned in the Wikipedia article above? Is there really something fundamental going on (the Holy Grail of investing) - or will this be the next Madoff?", "question_score": 28, "question_tags": ["strategy", "quant-funds"], "choices": {"A": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "B": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "C": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident...", "D": "There are a some information about Renaissance Technologies available in The Quants from Patterson. Basically, and it's also what I heard in general, they are using intensively algorithmic trading, and from what I understood there are using Information Theory (they worked with Shannon if I remember well). I'd say it'd be harsh to say it's the next Madoff given the background they have, I can easily see them being simply better than the rest... It's just my opinion of course..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/998/strategy-of-renaissance-technologies-medallion-fund-holy-grail-or-next-madoff"}
{"id": "finance_1628", "domain": "finance", "question_title": "What are the best sources for equity quantitative research?", "question_body": "What are the best sources of quantitative finance research in equities? I will list a couple and note an asterisk if the research is available by request (i.e. non-clients) or online: BAC-Merrill Lynch - Savita Subramanian Deutsche Bank - Yin Luo* Credit Suisse - Pankaj Patel Barclay's - Matthew Rothman HSBC - Ely Klepfish* Goldman Sachs - Quantitative Strategies Neuberger-Berman - Wai Lee Nomura - Joseph Mezrich Perhaps there are also more un-conventional sources of quant research besides sell-side wall street: Hussman Funds - John Hussman* Emanuel Derman's collection of papers", "question_score": 28, "question_tags": ["quant-trading-strategies", "equities", "research"], "choices": {"A": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "B": "Sell Side Macquarie Quant - Venkat Eleswarapu Bernstein Research - Vadim Zlotnikov Nomura - Joe Mezrich JPMorgan Investment Strategies series Societe Generale - Alain Bokobza Independent CXO Advisory Empirical Finance Blog Russell Indexes: Research and Insights MSCI Research Papers Axioma Research Papers", "C": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "D": "This question goes to whether the historical returns to factors represent: Spurious results, overfitting, data mining... Mispricing Unexploitable effects Compensation for risk Case 1: Spurious results etc... If someone constructs a \"stock tickers that begin with AAP or GOO\" factor, the highly above average returns would almost certainly reflect a fishing expedition (or conditioning on future information) and would not be reproducible going forward. Under a null of no above average returns, you're going to get portfolios that have above average historical returns with t-stats over 2. Beware. For something like the Fama-French factor $\\mathit{HML}$, this seems far less likely..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1628/what-are-the-best-sources-for-equity-quantitative-research"}
{"id": "finance_1710", "domain": "finance", "question_title": "Proof that you cannot beat a random walk", "question_body": "There is much speculation to what degree financial series are random (and what kind of randomness prevails). I want to turn the question on its head and ask: Is there a mathematical proof that whatever trading strategy you use you cannot beat a random walk (that is the expected value will always be 0 assuming no drift)? (I found this blog post where the author used the so called \"75% rule\" to purportedly beat a random walk but I think he got the distinction between prices and returns wrong. This method would only work if you had a range of allowed prices (e.g. a mean reverting series). See e.g. here for a discussion.)", "question_score": 28, "question_tags": ["quant-trading-strategies", "random-walk"], "choices": {"A": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "B": "I can help you beat random walk 'in the way you want', i.e. the expected value $E[\\$]$ will always be positive even assuming no drift. However, I have to warn people that $E[\\$] > 0$ is NOT really an adequate condition for 'beating' in reality (at least to myself). Let's define some mathematical notations for derivation, and rephrase (simplify) vonjd's question without losing generality. Assume a trader plays a fair game, and his surplus $X(0), X(1), X(2), ... X(t)$ is a martingale. Q: Can the trader find a stopping time $s$ such that $E[X($s$)] > X(0)$? A proof supporting Bootvis'...", "C": "Sell Side Macquarie Quant - Venkat Eleswarapu Bernstein Research - Vadim Zlotnikov Nomura - Joe Mezrich JPMorgan Investment Strategies series Societe Generale - Alain Bokobza Independent CXO Advisory Empirical Finance Blog Russell Indexes: Research and Insights MSCI Research Papers Axioma Research Papers", "D": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1710/proof-that-you-cannot-beat-a-random-walk"}
{"id": "finance_1888", "domain": "finance", "question_title": "Is the stock price process a martingale or a Markov process?", "question_body": "Some people claim that the data-generating process for stocks is a \"martingale\" and that is has the \"Markov property\". Are they unrelated? Is it that the Markov property implies some sort of martingale property, or is it the other way around? How do you statistically test for such properties? How far from reality is it to assume such properties?", "question_score": 28, "question_tags": ["equities", "martingale", "stochastic-processes"], "choices": {"A": "I know that I have seen things like this in the past. Wasn't there something recently that used Twitter? Here are a few recent papers as examples, although I will be brutally honest that I don't know if they speak to your decent quality requirement: \"Trading Strategies to Exploit Blog and News Sentiment\" (Zhang, Skiena 2010) \"The Predictive Power of Financial Blogs\" (Frisbee 2010) \"An analysis of verbs in financial news articles and their impact on stock price\" (Schumaker 2010)", "B": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "C": "From what I remember, there is no real relation between Markov and Martingale, and my intuition was confirmed by this post . Basically, it says that you can say neither of the following: If A is Markov, then A is a martingale. If A is a martingale, then A is Markov. further down the post, you can find two counter examples: $dX_t = a dt + \\sigma dW_t$ is Markov but not a martingale and $dX_t = (\\int_0^t X_s ds) dW_t$ is a Martingale but is not Markov. As for the assumption of these properties being true, I think it...", "D": "I recently read \"Modeling financial data with stable distributions\" (Nolan 2005) which gives a survey of this area and might be of interest (I believe it was contained in \"Handbook of Heavy Tailed Distributions in Finance\" ). Another more recent reference is \"Alpha-Stable Paradigm in Financial Markets\" (2008). I'm not aware of anything covering \"risk of fluctuations\" and this is still certainly not at the center of the field (i.e. most theory still includes some version of Gaussian or mixture of Gaussians). Would also be interested in other references."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1888/is-the-stock-price-process-a-martingale-or-a-markov-process"}
{"id": "finance_3368", "domain": "finance", "question_title": "Why is an inverted yield curve a problem?", "question_body": "Immediately preceding the worst of the financial crisis, my professors all pointed out to me that the yield curve had inverted -- short-term yields were more risky than 20-year or 30-year Treasury securities. My professors all seemed nervous about this. Aside from such a situation being generally counter-intuitive, why was this viewed so negatively? What kind of effects does this have, in a more macro sense?", "question_score": 28, "question_tags": ["theory", "yield-curve"], "choices": {"A": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "B": "Nano answer : declining yield curve is a symptom that the market expects the economy to worsen. Short answer : yield curve is built on expected future interest rates. Yield curve will be downward sloping if you expect interest rates to fall in the future. Interest rates fall because the central bank react to worsening economy. So if the yield curve is downward sloping it means the market expects the economy to worsen to the point that the central bank will have to intervene.", "C": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "D": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/3368/why-is-an-inverted-yield-curve-a-problem"}
{"id": "finance_11556", "domain": "finance", "question_title": "Why is the VIX futures market usually in a state of contango?", "question_body": "I'm a VIX newbie and I'm trying to understand why the VIX futures market is usually in a state of contango. All I can figure is that the sellers of VIX futures contracts demand high \"prices\" (because the seller is the holder of the short position and makes money when the price falls), and since there are willing buyers, namely ETNs and ETFs that are trying to track the S&P 500 VIX SHORT-TERM FUTURES INDEX (SPVIXSTR) through the purchase and sale of VIX futures, the contracts get sold. Also, the farther out the futures contract expires, the less certain the seller is about what the value of the VIX and the SPVIXSTR will be at the future's expiration date. The greater uncertainty over a longer term results in the seller demanding higher premiums over a longer term than he would demand over a shorter term. It seems like a prudent buyer of VIX futures wouldn't buy contracts that are priced so high. It seems like the VIX futures market should be in a state of contango about as frequently as it is in a state of backwardation. What causes contango in the VIX futures market, and why is it the usual state of the market?", "question_score": 28, "question_tags": ["volatility", "futures", "vix"], "choices": {"A": "Your questions about contango in VIX futures have close analogies in options too. The Black & Scholes model suggests that all time frames and all strikes should have the same implied volatility, but they don't. I think one of the reasons is that the B&S model assumes that stock returns are distributed in a normal (gaussian) distribution, but the actual returns don't match a gaussian distribution all that well. For example the actual occurrence of big crashes / gains is much more likely than a normal distribution would predict. Since crashes do occur people are willing to pay what the...", "B": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "C": "The term has a different meaning to different people. to econometricians, microstructure noise is a disturbance that makes high frequency estimates of some parameters (e.g. realized volatility) very unstable. Generally this strand of the literature professes agnosticism as to the its origin; to market microstructure researchers, microstructure noise is a deviation from fundamental value that is induced by the characteristics of the market under consideration, e.g. bid-ask bounce, the discreteness of price change, latency, and asymmetric information of traders. The last example is frequently cited but I don't think it is accurate. Asymmetric information does not have to be a...", "D": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/11556/why-is-the-vix-futures-market-usually-in-a-state-of-contango"}
{"id": "finance_1177", "domain": "finance", "question_title": "Why is volatility mean-reverting?", "question_body": "We all know it does mean revert. The question is why. What's making volatility mean-revert? Is it some sort of cyclical behaviour of option traders? The way it's calculated? Why?", "question_score": 27, "question_tags": ["volatility"], "choices": {"A": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we...", "B": "Volatility is mean reverting if the underlying security doesn't drop to zero. If the security has some underlying \"value\" then its price is co-integrated with that \"value\". The volatility is the uncertainty of that price as it tracks the security's \"value\". Edit 12/03/2011 ================================================= @pteetor, I may have missed something, but the question was \" Why is volatility mean-reverting?\". I realize that the standard answer is that the VIX (I'm assuming he's asking about the VIX) is related to the historical volatility of the S&P. A simple version of that relationship provides a reasonable R^2 (see Fig. 1). It relates...", "C": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "D": "It's an interesting question. I particularly agree with the $\\mathbb{Q}-\\mathbb{P}$ dichotomy mentioned by many. I would add to the other answers that, come to think of it, the Black-Scholes postulated Geometric Brownian Motion could be interpreted as an AR(1) process on the logarithm of the stock price as you discretise the SDE from which it is a solution, which is exactly what you do when running Monte-Carlo simulations (same thing for the Ornstein-Uhlenbeck process as explained here and noted by @Richard). Actually, when taking the continuous-time limit, many more econometric models can be shown to correspond to stochastic processes frequently..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1177/why-is-volatility-mean-reverting"}
{"id": "finance_2303", "domain": "finance", "question_title": "What does the VIX formula measure and how does it work?", "question_body": "I have read the CBOE's white paper on the VIX and a lot of other things, but I need to honestly say, I don't really get it, or I am missing something important. In semi-layman's terms, is the VIX simply the a measurement of the volume of protective options bought? That is, individual contract volatility increases when the option has been bid up by buyers due to desirability. One contract alone only marginally increases the overall market volatility, but if all contracts were bid up, then the entire VIX would be recalculated (on the fly) to reflect the higher value of protective options as a speculative/hedge solution. Do I understand this correctly, or do I really need to put more time into understanding that formula which comprises the VIX?", "question_score": 27, "question_tags": ["options", "volatility", "implied-volatility", "vix"], "choices": {"A": "VIX is a measure of implied volatility , specifically, model-free implied volatility , a concept originally developed by Demeterfi et. al. at Goldman Sachs in the 1990s . One of my recent questions, How to extrapolate implied volatility for out of the money options? , addressed some aspects of MFIV, and the papers mentioned in the question and answers will give you some more background on the concept. Also check out this JPMorgan research piece . The VIX is the square root of the market-implied variance swap rate, calculated based on the exchange-traded options portfolio typically used to hedge an...", "B": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "C": "Great question! I think the most useful starting point is Stock Return Characteristics, Skew Laws, and the Differential Pricing of Individual Equity Options by Bakshi, Kapadia and Madan (2003) . Their paper proposes a definition of model-free implied skewness (they originally called it risk-neutral skewness, but MFIS is more accurate), which they prove will have a P&L directly proportional to the realized skewness of the underlier. Subsequent papers (there are literally dozens) have thoroughly explored the properties of MFIS. In particular, Does Risk-Neutral Skewness Predict the Cross-Section of Equity Option Portfolio Returns? by Bali and Murray (2011) estimates the empirical...", "D": "Volatility is mean reverting if the underlying security doesn't drop to zero. If the security has some underlying \"value\" then its price is co-integrated with that \"value\". The volatility is the uncertainty of that price as it tracks the security's \"value\". Edit 12/03/2011 ================================================= @pteetor, I may have missed something, but the question was \" Why is volatility mean-reverting?\". I realize that the standard answer is that the VIX (I'm assuming he's asking about the VIX) is related to the historical volatility of the S&P. A simple version of that relationship provides a reasonable R^2 (see Fig. 1). It relates..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2303/what-does-the-vix-formula-measure-and-how-does-it-work"}
{"id": "finance_1391", "domain": "finance", "question_title": "Papers about backtesting option trading strategies", "question_body": "I am looking for all kinds of research concerning option trading strategies. With that I mean papers that publish results on different option trading strategies properly backtested with real-world data.", "question_score": 26, "question_tags": ["options", "backtesting", "quant-trading-strategies", "research", "option-strategies"], "choices": {"A": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a...", "B": "The way you do it in the first place is a discretization of the Geometric Brownian Motion (GBM) process. This method is most useful when you want to compute the path between $S_0$ and $S_t$, i.e. you want to know all the intermediary points $S_i$ for $0 \\leq i \\leq t$. The second equation is a closed form solution for the GBM given $S_0$. A simple mathematical proof showed that, if you know the initial point $S_0$ (which is $a$ in your equation), then the value of the process at time $t$ is given by your equation (which contains $W_t$,...", "C": "I did some digging and found the following papers - most of them offering quite a distinct perspective compared to classical option pricing theory! Stock Options as Lotteries by Brian H. Boyer et al. (2011) The Efficiency of the Buy-Write Strategy: Evidence from Australia by Tafadzwa Mugwagwa et al. (2010) The following is my favorite: You could do some backtests on your own with freely available data (using the VXO as volatility information) and with any spreadsheet - easy and elegant: How Students Can Backtest Madoff’s Claims by Michael J. Stutzer (2009) Loosening Your Collar: Alternative Implementations of QQQ Collars...", "D": "Strictly speaking, data snooping is not the same as in-sample vs out-of-sample model selection and testing, but has to deal with sequential or multiple tests of hypothesis based on the same data set. To quote Halbert White: Data snooping occurs when a given set of data is used more than once for purposes of inference or model selection. When such data reuse occurs, there is always the possibility that any satisfactory results obtained may simply be due to chance rather than to any merit inherent in the methody yielding the results. Let me provide an example. Suppose that you have..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1391/papers-about-backtesting-option-trading-strategies"}
{"id": "finance_2529", "domain": "finance", "question_title": "How do I adjust a correlation matrix whose elements are generated from different market regimes?", "question_body": "Say I want to calculate a correlation matrix for 50 stocks using 3-year historical daily data. And there are some stocks that were recently listed for one year. This is not technically challenging because the correlation function in R can optionally ignore missing data when calculating pair-wise correlation. But honestly it worried me after deep thought: all the correlations for the short listed stock will bias to the regime it live in. For example, a stock that exists only in last few months will inevitably have higher correlation than the stocks that have full 3-year history. And I think it will cause bias and annoying problems in the following applications using this correlation matrix. So, my question is: how do I adjust my correlation matrix whose elements are generated from different market regimes? I feel a dilemma. In order to assure that the whole matrix live in the same regime, it seems that either I need to use least possible samples, or I have to throw that stock away. But either way looks a waste to me. I know the correlations for that stock got to be lower, but how much lower? Is there an approach or formula derived from solid arguments? I did some research and surprisingly found that all public research on correlation matrix assuming adequateness of data. How can it be possible in practice?! A mystery for me to see this seemingly common problem has not been publicly addressed.", "question_score": 26, "question_tags": ["market-regimes", "correlation-matrix"], "choices": {"A": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "B": "Quant Guy's list is really impressive! However, I am not sure they will readily solve your specific problem? I think there is one missing piece . Please note that imputing missing data is a very broad topic. There are many recipes to impute missings but that's for their specific 'assumptions' and purposes. They do not necessarily intend to well address your specific problem: the regime change. To best address your specific problem, you have to quantitatively define the market regime as a part of your adjusting formula. Otherwise, it wouldn't logically make sense that your model is aware of and...", "C": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "D": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2529/how-do-i-adjust-a-correlation-matrix-whose-elements-are-generated-from-different"}
{"id": "finance_4160", "domain": "finance", "question_title": "Discrete returns versus log returns of assets", "question_body": "There have been similar posts here already but nevertheless I find the question worth posting: why do some people claim that log returns of assets are more suitable for statistics than discrete returns. E.g. in the ESMA CESR guidliens about SSRI log returns are used. I personally think that discrete returns are as good for means of risk management as continuous returns. Furthermore in portfolio context I can calculate the portfolio return by weighting the discrete returns of the assets which does not work with log returns. The time-aggregation of log returns is easier that's true. But people rather think in discrete returns. If my NAV drops from $100$ to $92$ then I have lost $8\\%$ and that's it. Is there any study on this - any good reference? Anything that I can tell my regulator why I stick to discrete returns.", "question_score": 26, "question_tags": ["asset-returns", "log-returns"], "choices": {"A": "Arithmetic returns allow for easier cross-sectional aggregation and log returns allow for easier time-aggregation. The reason people use log returns (for equities) is that they are approximately invariant and hence easier to work with in estimating distributions. Meucci does better justice in describing invariance here . The basic idea (again, for equities) is that the distribution of security prices is log-normal, so the arithmetic returns will also be. However, making a log transformation results in approximately normal returns, which are easier to work with. Also, if you do assume them to be normally distributed, then there are convenient results for...", "B": "Consider the standard error , and in particular the distance between the upper and lower limits: \\begin{equation} \\Delta = (\\bar{x} + SE \\cdot \\alpha) - (\\bar{x} - SE \\cdot \\alpha) = 2 \\cdot SE \\cdot \\alpha \\end{equation} Using the formula for standard error, we can solve for sample size: \\begin{equation} n = \\left(\\frac{2 \\cdot s \\cdot \\alpha}{\\Delta}\\right)^{2} \\end{equation} where $s$ is the measured standard deviation, which you already have from your IR calculation. High-frequency Example I was testing a market-making model recently that was expected to return a couple basis points for each trade and I wanted to be confident...", "C": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "D": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/4160/discrete-returns-versus-log-returns-of-assets"}
{"id": "finance_8843", "domain": "finance", "question_title": "What are modern algorithms for trade classification?", "question_body": "When dealing with trade data, for example from TAQ, a common problem is that of determining whether a trade was a buy or a sell . The most commonly used classifier is the Lee-Ready algorithm ( Inferring trade direction from intraday data , 1991). Unfortunately, this method is known to be inaccurate: Lee and Radhakrishna ( Inferring investor behaviour: evidence from TORQ data , 2000) report that Lee-Ready incorrectly classifies 24% of the trades inside the spread. How to improve on Lee-Ready's recipie? What are the best algorithms for trade classification?", "question_score": 26, "question_tags": ["market-microstructure"], "choices": {"A": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "B": "I've not yet read it, but Lehalle's recent book is bound to be a goldmine of good micro-structure bits and pieces. Market Microstructure in Practice EDIT: I'm reading the book now, so far it's quite good.", "C": "There are a few approaches to use trade prices and quotes to classify the aggressor as \"buy\" or \"sell.\" Also, many of these methods have historically had to deal with unsynchronized data streams. Classification of Approaches We can largely break trade classification methods into four types: Tick tests , advocated by Finucane (2000) , compare a trade price to the previous differing trade price with upticks (downticks) being evidence of a buy (sell); Midpoint tests , advocated by Lee and Ready (1991) , compare a trade price to a contemporaneous midpoint (average of bid and ask prices) with trades above...", "D": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through..."}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/8843/what-are-modern-algorithms-for-trade-classification"}
{"id": "finance_11564", "domain": "finance", "question_title": "Why shrink the covariance matrix?", "question_body": "I'm trying to understand why it's useful to shrink the covariance matrix for portfolio construction or in fact general. Think I missing something. I know if you have 5,000 stocks it's a lot of calculations but if we assume that computing power is not a problem.", "question_score": 26, "question_tags": ["statistics", "portfolio-management", "covariance", "portfolio-optimization"], "choices": {"A": "Have a look at this classic paper: Honey, I Shrunk the Sample Covariance Matrix by O. Ledoit and M. Wolf The abstract answers your question already: The central message of this article is that no one should use the sample covariance matrix for portfolio optimization. It is subject to estimation error of the kind most likely to perturb a mean-variance optimizer. Instead, a matrix can be obtained from the sample covariance matrix through a transformation called shrinkage. This tends to pull the most extreme coefficients toward more central values, systematically reducing estimation error when it matters most. Statistically, the challenge...", "B": "The term has a different meaning to different people. to econometricians, microstructure noise is a disturbance that makes high frequency estimates of some parameters (e.g. realized volatility) very unstable. Generally this strand of the literature professes agnosticism as to the its origin; to market microstructure researchers, microstructure noise is a deviation from fundamental value that is induced by the characteristics of the market under consideration, e.g. bid-ask bounce, the discreteness of price change, latency, and asymmetric information of traders. The last example is frequently cited but I don't think it is accurate. Asymmetric information does not have to be a...", "C": "In my experience, a VaR or CVaR portfolio optimization problem is usually best specified as minimizing the VaR or CVaR and then using a constraint for the expected return. As noted by Alexey, it is much better to use CVaR than VaR. The main benefit of a CVaR optimization is that it can be implemented as a linear programming problem. Another option I have tried is the technique in this paper: http://www.math.uwaterloo.ca/~tfcolema/articles/bank_article.pdf Another option is the two-step heuristic where one first finds the mean-variance efficient frontier and then you could calculate whatever are the relevant portfolio statistics on only the...", "D": "Just to be painfully clear, it only seems to make sense to consider the logarithm of returns, i.e. $X=\\log (1+\\frac r{100})$ for a simple return of $r\\%$ in an arbitrary period because this is what sums when returns are temporally aggregated. A basic property of cumulants is that cumulants of all orders are additive under convolution, for which a proof can be found here here . So if $X_1$, $X_2$, ... $X_n$ are i.i.d. , then all the cumulants of $$Y_n = \\sum_{i=1}^nX_i$$ scale linearly with $n$, i.e. $$\\kappa_k(Y_n)=n\\kappa_k(Y_1).$$ However, I suspect that you are normalizing this sum so that..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/11564/why-shrink-the-covariance-matrix"}
{"id": "finance_344", "domain": "finance", "question_title": "What is the implied volatility skew?", "question_body": "I often hear people talking about the skew of the volatility surface, model, etc... but it appears to me that there isn't a clear standard definition unanimously used by practitioners. So here is my question: Does anyone have a clear and unifying definition that can be stated in mathematical terms of what skew is in the context of risk neutral pricing? If not, do you have a set of definitions of the skew with respect to a specific context?", "question_score": 25, "question_tags": ["options", "option-pricing", "implied-volatility", "volatility-skew"], "choices": {"A": "Intro: Great answer given by Kevin. I would like to contribute an additional perspective. My experience with and my understanding of the Risk Neutral measure is entirely based on \"no arbitrage\" and \"replication / hedging\" arguments. The way I would like to explain this view is via the following three-step construction : (i) First, I want to build the intuition with a one-period discrete model: only a single stock and a risk-free account, no derivatives . The aim is to show that even without trying to price derivatives, one can create a mathematical object called a \"risk-neutral probability measure\", just...", "B": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "C": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "D": "Scott Mixon argues in What Does Implied Volatility Skew Measure that among all measures of implied volatility skew, the (25 delta put volatility - 25 delta call volatility)/50 delta volatility is the most descriptive and least redundant (volatility is Black-Scholes implied volatility). His paper, recently published in the Journal of Derivatives , gives a number of both theoretical and empirical arguments in favor of this measure. He distinguishes between \"skew\", which is a measure of the slope of the implied volatility curve for a given expiration date, and \"skewness\", which is the skewness of an option implied, risk neutral probability..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/344/what-is-the-implied-volatility-skew"}
{"id": "finance_529", "domain": "finance", "question_title": "How to quickly estimate a lower bound on correlation for a large number of stocks?", "question_body": "I would like to find stock pairs that exhibit low correlation. If the correlation between A and B is 0.9 and the correlation between A and C is 0.9 is there a minimum possible correlation for B and C? I'd like to save on search time so if I know that it is mathematically impossible for B and C to have a correlation below some arbitrary level based on A to B and A to C's correlations I obviously wouldn't have to waste time calculating the correlation of B and C. Is there such a \"law\"? If not, what are other methods of decreasing the search time?", "question_score": 25, "question_tags": ["time-series", "correlation", "numerical-methods"], "choices": {"A": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "B": "Yes, there is such a rule and it is not too hard to grasp. Consider the 3-element correlation matrix $$\\left(\\begin{matrix} 1 & r & \\rho \\\\ r & 1 & c \\\\ \\rho & c & 1 \\end{matrix}\\right)$$ which must be positive semidefinite . In simpler terms, that means all its eigenvalues must be nonnegative. Assuming that $\\rho$ and $r$ are known positive values, we find that the eigenvalues of this matrix go negative when \\begin{equation} c Therefore the right hand side of this expression is the lower bound for the AC correlation $c$ that you seek, with $\\rho$ being...", "C": "It is hard to find a stable non-trivial dependence structure in financial data. Usually when such is found it is hard to rationalize. One of my favorite (although I am sure there are others) is the so called \"Presidential Puzzle\". This is an old finding by Santa-Clara and Valkanov (2003) They find that \" Excess return in the stock market is higher under Democratic than Republican presidencies: 9 percent for the value‐weighted and 16 percent for the equal‐weighted portfolio. At the time the finding was very robust and did not seem to be explained by anything else. What is more...", "D": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/529/how-to-quickly-estimate-a-lower-bound-on-correlation-for-a-large-number-of-stock"}
{"id": "finance_10401", "domain": "finance", "question_title": "What is the necessary level of Econometrics-Know-How for a quant", "question_body": "It seems quants increasingly use econometric models at work. As someone who has sold his soul to probability theory and stochastical analysis I would like to catch up. What are the econometric tools a quant should be able to wield ? As I see it, the answer will be highly dependant on where one works. Thus perhaps it would make sense to distinguish: Buy side Sell side Fixed Income Equity Risk Management and Model Validation Book suggestions that cover the necessary knowledge will be appreciated. Also, if someone feels like it, a list of topics (e.g. ARCH, GARCH etc.) would also be very helpful.", "question_score": 25, "question_tags": ["risk-models", "econometrics", "quants"], "choices": {"A": "I can only talk about quantitative trading. As a rule of thumb, the lower frequency you work in, the more econometrics is important, whereas for a higher frequency, the more econometrics becomes useless . (I would still recommend a top econometrician for HFT since they have what it takes to succeed, it's just the models aren't out-of-the-box applicable.) But if I was interviewing someone who was educated in econometrics for a quantitative research position, I would hope for (given the relevance to financial time-series): I have tried to put in a legend, ^ is something you should learn later and...", "B": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "C": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "D": "Wavelets are just one form of \"basis decomposition\". Wavelets in particular decompose in both frequency and time and thus are more useful than fourier or other purely-frequency based decompositions. There are other time-freq decompositions (for instance the HHT) which should be explored as well. Decomposition of a price series is useful in understanding the primary movement within a series. In general with a decomposition, the original signal is the sum its basis components (potentially with some scaling multiplier). The components range from the lowest frequency (a straight-line through the sample) to the highest frequency, a curve that oscillates with a..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/10401/what-is-the-necessary-level-of-econometrics-know-how-for-a-quant"}
{"id": "finance_17859", "domain": "finance", "question_title": "Why dynamics of local volatility is wrong?", "question_body": "In Dupire's local volatility model, the volatility is is a deterministic function of the underlying price and time, chosen to match observed European option prices. To be more specific, given a smooth surface $(K,T)\\mapsto C(K,T)$ where K is the strike and T is time to maturity. Dupire equation implies that there exits an unique continuous function $\\sigma_{loc}$ defined by $$\\sigma_{loc}^{2}(K,T)=\\frac{\\partial_{T}C(K,T)+rK\\partial_{K}C(K,T)}{\\frac{1}{2}K^{2}\\partial_{KK}C(K,T)}$$ for all $(K,T)\\in(0,\\infty)\\times(0,\\infty)$ such that the solution to the stochastic differential equation $dS_{t}/S_{t}=rdt+\\sigma(t,S_{t})dW_{t}$ exactly generates the European call option prices. What do the dynamics of the local volatility mean? Are dynamics equivalent to the volatility surface? Why the dynamics of local volatility model is highly unrealistic?", "question_score": 25, "question_tags": ["local-volatility", "dynamic"], "choices": {"A": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "B": "A general model (with continuous paths) can be written $$ \\frac{dS_t}{S_t} = r_t dt + \\sigma_t dW_t^S $$ where the short rate $r_t$ and spot volatility $\\sigma_t$ are stochastic processes. In the Black-Scholes model both $r$ and $\\sigma$ are deterministic functions of time (even constant in the original model). This produces a flat smile for any expiry $T$. And we have the closed form formula for option prices $$ C(t,S;T,K) = BS(S,T-t,K;\\Sigma(T,K)) $$ where $BS$ is the BS formula and $\\Sigma(T,K) = \\sqrt{\\frac{1}{T-t}\\int_t^T \\sigma(s)^2 ds}$. This is not consistent with the smile observed on the market. In order to match...", "C": "The minimum variance solution loads up on securities that have low variances and co-variances. Theoretically you are correct that this should have a low expected return profile. However, it turns out - in contradiction to modern portfolio theory - that securities that have low-volatility or low-beta experience higher returns than high-volatility or high-beta stocks. This is well-documented in the literature as the low-volatility anomaly . As a result, many funds and ETFs have been launched in recent years to exploit this phenomenon. There are a couple arguments as to why the anomaly exists. The paper I cite above argues that...", "D": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have..."}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/17859/why-dynamics-of-local-volatility-is-wrong"}
{"id": "finance_36400", "domain": "finance", "question_title": "Avellaneda -Stoikov market making model", "question_body": "I am reading paper High-frequency trading in a limit order book by Marco Avellaneda and Sasha Stoikov. At the end of the paper they obtain a closed-form solution to the optimal market-maker quotes under diffusion without drift. They found that the optimal behaviour of the market-maker would be to set a bid/ask spread of size: $$ spread = \\gamma\\sigma^2(T-t) + \\frac{2}{\\gamma}ln(1+\\frac{\\gamma}{k}), $$ where $\\gamma$ is a discount factor, $\\sigma^2$ is the variance of the process, $k$ is the parameter corresponing to the intensity of arrival of market orders, $T$ is terminal time and $t$ is curent time, around a reservation price given by: $$ price = s - q\\gamma\\sigma^2(T-t), $$ where $q$ is the state of the inventory and $s$ is the current price. However, I do not see any specification of bounds for this reservation price and therefore I think there is no guarantee that ask prices computed by the market-maker will be higher or bid prices will be lower than the current price of the process. | How is this necessity of market makers' ask prices being higher and bid prices being lower than the actual price enforced in their model (e.g. in their simulations)? Edit : To be more concrete, I just specify, that in my opinion, it needs to hold that: $$ price + spread/2 - s > 0 $$ Lets denote $price$ by $p_{mm}$ and $spread/2$ by $s_{mm}$ . Then $$ p_{mm} + s_{mm} - s > 0, \\\\ s - q\\gamma\\sigma^2(T-t) + \\frac{\\gamma\\sigma^2(T-t)}{2} + \\frac{1}{\\gamma}ln(1+\\frac{\\gamma}{k}) - s >0 \\\\ (...) \\\\ \\frac{1}{2} + \\frac{ln(1+\\frac{\\gamma}{k})}{\\gamma^2\\sigma^2(T-t)} > q $$ However, this situation does not need to happen, so there is no guarantee he will set prices compatible with current market prices.", "question_score": 25, "question_tags": ["high-frequency", "market-making"], "choices": {"A": "The market-maker makes a bid-ask spread $\\delta$ around the reservation price $r$. So at any time, the market-maker quotes the bid price $$ p_b = r - \\delta/2, $$ and the ask price $$ p_a = r + \\delta/2. $$ Bid price is hence always below the reservation price and ask price is always above the reservation price. The reservation price $$ r = s - q\\gamma\\sigma^2(T-t) $$ is the market price minus a term that depends on the inventory $q$ that the market-maker is holding. If $q$ is positive the reservation price moves lower (below the market price) and...", "B": "The lead paper in the January 2011 Journal of Finance ( Hendershott, Jones, and Menkveld ) addresses algorithmic trading (AT). In short, they find that AT improves liquidity as measured by bid-offer spreads. Taking the econometrics as correct (it is in the Journal of Finance) the next question is if bid-offer spreads are a sufficient statistic for measuring liquidity (or any other benefits). It is a difficult question to answer because, given current market structure, AT may improve liquidity (as measured by bid-offer spreads), but without data on other market structures, it is hard to say that we wouldn't better...", "C": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "D": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters...."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/36400/avellaneda-stoikov-market-making-model"}
{"id": "finance_96", "domain": "finance", "question_title": "What is a "coherent" risk measure?", "question_body": "What is a coherent risk measure, and why do we care? Can you give a simple example of a coherent risk measure as opposed to a non-coherent one, and the problems that a coherent measure addresses in portfolio choice?", "question_score": 24, "question_tags": ["risk", "modern-portfolio-theory", "coherent-risk-measure"], "choices": {"A": "I'm just providing a global answer to the question, as I think it can be interesting for some beginners in quant finance. The properties given by TheBridge: Normalize $\\rho (\\emptyset)=0$ This means you have no risk in taking no position. Sub-addiitivity $\\rho(A_1+A_2) \\leq \\rho(A_1)+\\rho(A_2)$ Having a position in two different can only decrease the risk of the portfolio (diversification) Positive homogeneity $\\rho(\\lambda A) = \\lambda \\rho(A)$ Doubling a position in an asset A doubles your risk. And finally, Translation invariance $\\rho(A + x) = \\rho(A)-x$ That is, adding cash to a portfolio only diminishes the risk. So a risk-measure is...", "B": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters....", "C": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "D": "I would offer the distinctions are i) pure statistical approach, ii) equilibrium based approach, and iii) empirical approach. The statistical approach includes data mining. Its techniques originate in statistics and machine learning. In its extreme there is no a priori theoretical structure imposed on asset returns. Factor structure might be identified thru Principal Components, for example. The goal here is to maximize predictive accuracy at the expense of intuition and explanatory power. This approach increasingly dominates at very short frequencies in modeling market microstructure, market making algorithms, volatility modeling, etc. However, even in high-frequency trading one can impose a factor..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/96/what-is-a-coherent-risk-measure"}
{"id": "finance_334", "domain": "finance", "question_title": "Does mean-variance portfolio optimization provide a real edge to those who use it?", "question_body": "Mean-variance optimization (MVO) is a 50+ year concept, and perhaps the first seminal idea of quantitative finance. Still, as far as I know, less than 25% of AUM in the US is quantitatively managed. While a small minority of fundamental managers use MVO, that is counterbalanced by statistical arbitrage and HF strategies that often use optimization but not MVO, so the percentage of AUM not allocated using Markowitz' invention is surely not less than 70%. My questions: if MVO is such a great idea, why after all this time, so few people use it? if MVO was such a bad idea, how come companies like Axioma, Northfield and Barra still make money off it? is there there a rationale for the current mixed equilibrium of users and non-users? A few caveats on what I just said: i) perhaps the first and most important idea in finance is that of state-contingent assets, which is Arrow's; ii) I am focused on the buy side. I believe that optimization is widely used for hedging on the sell side.", "question_score": 24, "question_tags": ["mean-variance", "optimization"], "choices": {"A": "I would offer the distinctions are i) pure statistical approach, ii) equilibrium based approach, and iii) empirical approach. The statistical approach includes data mining. Its techniques originate in statistics and machine learning. In its extreme there is no a priori theoretical structure imposed on asset returns. Factor structure might be identified thru Principal Components, for example. The goal here is to maximize predictive accuracy at the expense of intuition and explanatory power. This approach increasingly dominates at very short frequencies in modeling market microstructure, market making algorithms, volatility modeling, etc. However, even in high-frequency trading one can impose a factor...", "B": "Hey, it's early days yet. After all it is still called MODERN portfolio theory. I think there are two main issues and they are both really cultural: 1) specifying alphas 2) wild results Alphas I agree with Gappy that alphas are the key thing you need to have effectiveness (unless you are doing minimum variance). Having a vector of expected returns is quite a natural thing for quant managers. But it is something foreign to fundamental managers. They have to map their views into a number for each asseet in the universe. That is not necessarily an easy task, and...", "C": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "D": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)"}, "answer": "B", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/334/does-mean-variance-portfolio-optimization-provide-a-real-edge-to-those-who-use-i"}
{"id": "finance_1114", "domain": "finance", "question_title": "Why are options trades supposed to be delta-neutral?", "question_body": "I'm reading Natenberg's book, and he says that all options trades should be delta neutral. I understand that this prevents small changes in the underlying price from changing the price of the option, but couldn't there be a case where you would want that? I (think I) also understand that if you're betting against just volatilty, it would make sense, since you don't care what direction the underlying price moves, but I don't entirely understand why he says all options trades should be delta neutral.", "question_score": 24, "question_tags": ["options", "delta-neutral"], "choices": {"A": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "B": "Scott Mixon argues in What Does Implied Volatility Skew Measure that among all measures of implied volatility skew, the (25 delta put volatility - 25 delta call volatility)/50 delta volatility is the most descriptive and least redundant (volatility is Black-Scholes implied volatility). His paper, recently published in the Journal of Derivatives , gives a number of both theoretical and empirical arguments in favor of this measure. He distinguishes between \"skew\", which is a measure of the slope of the implied volatility curve for a given expiration date, and \"skewness\", which is the skewness of an option implied, risk neutral probability...", "C": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "D": "I haven't read Natenberg but it of course depends on your side in the trade: Are you a market maker or a risk taker? So do you live on the spread (first) or are trying to make money based on e.g. forecasts on direction (second). This is the great divide in QuantFinance! Only in the first case will all your option trades be delta neutral. There is a nice short paper which elaborates on both concepts (it calls the first one Q and the second P ): Meucci: 'P' Versus 'Q': Differences and Commonalities between the Two Areas of Quantitative..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/1114/why-are-options-trades-supposed-to-be-delta-neutral"}
{"id": "finance_3284", "domain": "finance", "question_title": "Is "eoddata" a good data source?", "question_body": "Not sure if this is a relevant question for site, but I am looking to move to www.eoddata.com as my data source. If anyone has used it, can you tell me how the data quality is ? I am currently parsing yahoo for my prices but its not a very efficient process. What are the other sources of equity data out there ( affordable for retail investors like me) ? I am willing to pay \\$250-\\$300 per year for it.", "question_score": 24, "question_tags": ["data", "market-data"], "choices": {"A": "Yahoo rounds the adjusted price to 2 decimals even though dividend amounts often have 3 decimal places. Since they apply the adjustment formula to adjusted prices, if you go far enough back in time, the value they give for Adjusted Price will be different than it would be if there were no rounding. edit: For example, for C (Citigroup), on January 2, 1990, Yahoo gives a close value of 29.37 and an Adjusted value of 1.50. Using the dividend data that Yahoo supplies, if they didn't round to cents on every adjustment, the adjusted value would be 1.677.", "B": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters....", "C": "Because of: The (extreme) dominance of noise over signal The prevalence of non-repeating patterns (many of which we know are not going to repeat) A pathetic sample size for cross-validation Regime changes due to exogenous events. These are typically in the cross-val window which makes it even worse. (GFC, financial integration, trade law changes, interest rate adjustments by central banks, some idiot in a bank was hiding trades and loses 5 billions dollars, etc). It is well known that non-linear relationships are generally just artefacts of the in sample dataset There is also the following: Much price changes are driven...", "D": "From my experience, EODData is pretty much that you get what you pay for. Its not a very sophisticated product. They email you the files you subscribe to, and thats that. I have had an issue before of where the emails didn't go through anymore and I never heard anything from them. On Quality, I can't make a claim on its accuracy. It seems good. I find issue with three things about the data: There is no way to signal an exchange change It doesn't give you an easy way to grab the symbol info [Names, etc] If there is..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/3284/is-eoddata-a-good-data-source"}
{"id": "finance_54362", "domain": "finance", "question_title": "Did Citigroup really fail three times in the last 40 years?", "question_body": "I watched a speech by Simon Johnson at UCSB and, at one point, he claimed that Citigroup has failed three times since the 1980s. For example, he claims that Citigroup failed and was saved by the government in 1982 because of \"bad loans made in emerging markets\". The second such failure is at the end of the 1980s because of \"bad loans to commercial real estate\". The third is of course the 2008/2009 financial crisis. What strikes me as odd is that the first two alleged failures are not mentioned in Wikipedia on Citigroup ! He doesn't appear to me as a crackpot as he is the former chief economist of IMF and effective whitewashing of the US's biggest bank holding company on Wikipedia is as unlikely. Does anyone know what affairs is he referencing?", "question_score": 24, "question_tags": ["banks"], "choices": {"A": "(I worked there for 23 years.) Simon Johnson is correct. Citi (or its predecessors) was insolvent on those 3 occasions, and would have gone into liquidation without the bailouts by U.S. taxpayers.", "B": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very...", "C": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "D": "It's an interesting question. I particularly agree with the $\\mathbb{Q}-\\mathbb{P}$ dichotomy mentioned by many. I would add to the other answers that, come to think of it, the Black-Scholes postulated Geometric Brownian Motion could be interpreted as an AR(1) process on the logarithm of the stock price as you discretise the SDE from which it is a solution, which is exactly what you do when running Monte-Carlo simulations (same thing for the Ornstein-Uhlenbeck process as explained here and noted by @Richard). Actually, when taking the continuous-time limit, many more econometric models can be shown to correspond to stochastic processes frequently..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/54362/did-citigroup-really-fail-three-times-in-the-last-40-years"}
{"id": "finance_14", "domain": "finance", "question_title": "What is the "delta" option quoting convention about?", "question_body": "At my work I often see option prices or vols quoted against deltas rather than against strikes. For example for March 2013 Zinc options I might see 5 quotes available for deltas as follows: ZINC MARCH 2013 OPTION DELTA -10 POINTS ZINC MARCH 2013 OPTION DELTA -25 POINTS ZINC MARCH 2013 OPTION DELTA +10 POINTS ZINC MARCH 2013 OPTION DELTA +25 POINTS ZINC MARCH 2013 OPTION DELTA +50 POINTS The same 5 values -10, -25, +10, +25, + 50 are always used. What are these deltas? What are the units? Why are those 5 values chosen?", "question_score": 23, "question_tags": ["options", "greeks"], "choices": {"A": "Delta is the partial derivative of the value of the option with respect to the value of the underlying asset. An option with a delta of 0.5 (here listed as +50 points) goes up \\$0.50 if the underlying asset goes up \\$1.00. Or goes down \\$0.50 if the underlying asset goes down \\$1.00. Keep in mind that delta is an instantaneous derivative, so the value will change both in time (charm is the change in delta with time) and with changes in value of the underlying asset (gamma is the change in delta with the underlying asset, which is also...", "B": "Scott Mixon argues in What Does Implied Volatility Skew Measure that among all measures of implied volatility skew, the (25 delta put volatility - 25 delta call volatility)/50 delta volatility is the most descriptive and least redundant (volatility is Black-Scholes implied volatility). His paper, recently published in the Journal of Derivatives , gives a number of both theoretical and empirical arguments in favor of this measure. He distinguishes between \"skew\", which is a measure of the slope of the implied volatility curve for a given expiration date, and \"skewness\", which is the skewness of an option implied, risk neutral probability...", "C": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "D": "VIX is a measure of implied volatility , specifically, model-free implied volatility , a concept originally developed by Demeterfi et. al. at Goldman Sachs in the 1990s . One of my recent questions, How to extrapolate implied volatility for out of the money options? , addressed some aspects of MFIV, and the papers mentioned in the question and answers will give you some more background on the concept. Also check out this JPMorgan research piece . The VIX is the square root of the market-implied variance swap rate, calculated based on the exchange-traded options portfolio typically used to hedge an..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/14/what-is-the-delta-option-quoting-convention-about"}
{"id": "finance_121", "domain": "finance", "question_title": "How do you evaluate a covariance forecast?", "question_body": "Suppose you have two sources of covariance forecasts on a fixed set of $n$ assets, method A and method B (you can think of them as black box forecasts, from two vendors, say), which are known to be based on data available at a given point in time. Suppose you also observe the returns on those $n$ assets for a following period (a year's worth, say). What metrics would you use to evaluate the quality of these two covariance forecasts? What statistical tests? For background, the use of the covariances would be in a vanilla mean-variance optimization framework, but one can assume little is known about the source of alpha. edit : forecasting a covariance matrix is a bit different, I think, than other forecasting tasks. There are some applications where getting a good forecast of the eigenvectors of the covariance would be helpful, but the eigenvalues are not as important. (I am thinking of the case where one's portfolio is $\\Sigma^{-1}\\mu$, rescaled, where $\\Sigma$ is the forecast covariance, and $\\mu$ is the forecast returns.) In that case, the metric for forecasting quality should be invariant with respect to scale of the forecast. For some cases, it seems like forecasting the first eigenvector is more important (using it like beta), etc . This is why I was looking for methods specifically for covariance forecasting for use in quant finance.", "question_score": 23, "question_tags": ["forecasting", "statistics", "covariance"], "choices": {"A": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "B": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "C": "A general model (with continuous paths) can be written $$ \\frac{dS_t}{S_t} = r_t dt + \\sigma_t dW_t^S $$ where the short rate $r_t$ and spot volatility $\\sigma_t$ are stochastic processes. In the Black-Scholes model both $r$ and $\\sigma$ are deterministic functions of time (even constant in the original model). This produces a flat smile for any expiry $T$. And we have the closed form formula for option prices $$ C(t,S;T,K) = BS(S,T-t,K;\\Sigma(T,K)) $$ where $BS$ is the BS formula and $\\Sigma(T,K) = \\sqrt{\\frac{1}{T-t}\\int_t^T \\sigma(s)^2 ds}$. This is not consistent with the smile observed on the market. In order to match...", "D": "You are correct: evaluating volatility forecasts is quite different from evaluating forecasts in general, and it is a very active area of research. Methods can be classified in several ways. One criterion is to consider evaluation methods for single forecasts (e.g., for the time series of returns of a specific portfolio) vs multiple simultaneous forecasts (e.g., for an investable universe). Another criterion is to separate direct evaluation methodsfrom indirect evaluation methods (more on this later). Focusing on single-asset methods: historically the most commonly used approach by practitioners, and the one advocated by Barra is the \"bias\" statistics. If you have..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/121/how-do-you-evaluate-a-covariance-forecast"}
{"id": "finance_2000", "domain": "finance", "question_title": "When should you build your own equity risk model?", "question_body": "Commercial risk models (e.g., Barra , Axioma , Barclays , Northfield ) have evolved to a very high level of sophistication. However, all of these models attempt to solve a very broad set of problems. The optimal risk model for, say, risk attribution in a fundamental portfolio may differ substantially from the optimal risk model for downside risk estimation of an optimized quantitative strategy or for hedging unwanted exposures in a pure relative value play. Suppose that one already subscribes to a decent risk model provider, so that cost is not an issue. For what applications is it most appropriate to build your own equity risk model? What are the main benefits of a customized risk model? When is it worth the time and effort to replicate the increasingly sophisticated data cleaning/analysis and statistical methods to reap these benefits?", "question_score": 23, "question_tags": ["risk", "equities", "risk-models"], "choices": {"A": "1. Determine Factors Economically, the use of factor models can be either motivated using the ICAPM or the APT . Although there are some theoretical differences between the model, for empirical and practical work these differences are irrelevant. In the end, both models stipulate that returns and expected returns are linear functions of the factors: $$ r_{i,t} = \\alpha_i + \\sum_j \\beta_{i,j} F_{j,t} + \\epsilon_{i,t} \\quad (1)$$ $$ \\mathbb{E}[ r_{i,t}] = \\lambda_o + \\sum_j \\beta_{i,j} \\lambda_j \\quad\\quad\\quad(2)$$ where $F_{j,t}$ is the factor surprise of factor $j$ at time $t$ and $\\lambda_j $ is the factor risk premium of factor $j$....", "B": "Here couple pointers that may make it clearer: Drift can be replaced by the risk-free rate through a mathematical construct called risk-neutral probability pricing. Why can we get away with that without introducing errors? The reason lies in the ability to setup a hedge portfolio, thus the market will not compensate us for the drift above and beyond the risk free rate under risk-neutral probability pricing. As long as such hedge exists and couple other conditions are met (please look up Girsanov's Theorem) we can introduce a risk-neutral measure so that when applying it to the differential equation and through...", "C": "I think you're overlooking a third explanation: Nobody that found a successful technique to generate alpha has published it. I can think of the following causes: If you're an academic, why share your brilliant idea? These techniques require a lot of data and financial data can be expensive, researches that work at firms that have access to this data don't share their findings with the public. Academics did find a lot of signals already the old fashioned way. Despite this, fancy techniques such as AAD and Reinforcement Learning are discussed publicly. These methods don't generate any alpha however.", "D": "Great question. We would expect 3rd party risk providers to have specialized expertise (robust regression techniques, factor research, data cleansing etc.). We might grant them these advantages but still find weakness in the product design. Let's start off with the different uses of risk models and the procedure or metric which is maximized to solve for that use case. What we will see is that solving for a particular objective diminishes our ability to achieve other objectives. Portfolio construction = If you want to construct a minimum variance portfolio, for example, then the key here is developing a covariance matrix..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2000/when-should-you-build-your-own-equity-risk-model"}
{"id": "finance_2332", "domain": "finance", "question_title": "How to combine multiple trading algorithms?", "question_body": "Is it possible to combine different algorithms so as to improve trading performance? In particular, I have read that social media sentiment tracking, digital signal processing and neural networks all can be used for trading algorithms. Would it be possible to create a trading algorithm that combines elements from these three areas or are these methods mutually exclusive in that they are incompatible with each other? If you commit to one, can you use the other?", "question_score": 23, "question_tags": ["trading", "algorithmic-trading", "quant-trading-strategies", "performance"], "choices": {"A": "In order to answer your question (for you) you would need something to compare to . You would need numbers to know if it is slower/faster, how much, and if it will impact your system overall. Also knowing your performance goals could narrow down the options. My advice is to take a look at your overall architecture of the sytem you have or intend to build. To just look at QuickFIX is rather meaningless without the whole chain involved in processing information and reacting to it . As an example, say QuickFIX is 100 times faster than some part (in...", "B": "The way you do it in the first place is a discretization of the Geometric Brownian Motion (GBM) process. This method is most useful when you want to compute the path between $S_0$ and $S_t$, i.e. you want to know all the intermediary points $S_i$ for $0 \\leq i \\leq t$. The second equation is a closed form solution for the GBM given $S_0$. A simple mathematical proof showed that, if you know the initial point $S_0$ (which is $a$ in your equation), then the value of the process at time $t$ is given by your equation (which contains $W_t$,...", "C": "This isn't really an answer, but it's too long to add as a comment. I've always had a real problem with the correlation/covariance of price . To me, it means nothing. I realize that it gets used (abused) in many contexts, but I just don't get anything out of it (over time, price has to generally go up, go down, or go sideways, so aren't all prices \"correlated\"?). On the flip side, correlation/covariance of returns makes sense. You're dealing with random series, not integrated random series. For example, below is the code required to generate two price series that have...", "D": "Yes. First, it is much easier to proceed if you standardize the output of your forecast so they are in the same units (returns, for example, or probabilities of an event/condition occurring). After you have done this, there are 3 general approaches: Signal weighting: Then you need to define a weighting scheme for your factors. Richard Grinold has an one answer to this question in his paper \" Signal Weighting \". Note there are quite a few methods to weight signals (optimization, meta-models, forecast pooling, Bayesian model averaging, weighing based on out-of-sample performance, etc.). The general problem of \"Signal Weighting\"..."}, "answer": "D", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/2332/how-to-combine-multiple-trading-algorithms"}
{"id": "finance_3667", "domain": "finance", "question_title": "Skewness and Kurtosis under aggregation", "question_body": "Returns possess non-zero skewness and excess kurtosis. If these assets are temporally aggregated both will disappear due to the law of large numbers. To be exact, if we assume IID returns skewness scales with $\\frac{1}{\\sqrt{n}}$ and kurtosis with $\\frac{1}{n}$. I'm interested in a concise, clear and openly accessible proof for the above statement preferably for all higher moments. This question is inspired by this question by Richard which deals with, among other things, the behaviour of the higher moments of returns under temporal aggregation. I know about two papers that answer this question. Hawawini (1980) is wrong and Hon-Shiang and Wingender (1989) is behind a paywall and a bit inscrutable.", "question_score": 23, "question_tags": ["statistics", "returns", "volatility-skew", "kurtosis"], "choices": {"A": "Just to be painfully clear, it only seems to make sense to consider the logarithm of returns, i.e. $X=\\log (1+\\frac r{100})$ for a simple return of $r\\%$ in an arbitrary period because this is what sums when returns are temporally aggregated. A basic property of cumulants is that cumulants of all orders are additive under convolution, for which a proof can be found here here . So if $X_1$, $X_2$, ... $X_n$ are i.i.d. , then all the cumulants of $$Y_n = \\sum_{i=1}^nX_i$$ scale linearly with $n$, i.e. $$\\kappa_k(Y_n)=n\\kappa_k(Y_1).$$ However, I suspect that you are normalizing this sum so that...", "B": "There are some cases where you can blend your portfolios using weights directly. One case involves corner portfolios . In this case a linear combination of weights is also efficient. Another case is where you can treat the two separate weights you have produced each as distinct portfolio under the assumption that the correlation between these portfolios is relatively stable. In this scenario, the problem reduces to a two-asset portfolio optimization problem (each asset is simply the linear combination of weights produced via your two methods). The other class of methods involves blending via the expected returns. If you arrived...", "C": "The term has a different meaning to different people. to econometricians, microstructure noise is a disturbance that makes high frequency estimates of some parameters (e.g. realized volatility) very unstable. Generally this strand of the literature professes agnosticism as to the its origin; to market microstructure researchers, microstructure noise is a deviation from fundamental value that is induced by the characteristics of the market under consideration, e.g. bid-ask bounce, the discreteness of price change, latency, and asymmetric information of traders. The last example is frequently cited but I don't think it is accurate. Asymmetric information does not have to be a...", "D": "There seems to be a basic fallacy that someone can come along and learn some machine learning or AI algorithms, set them up as a black box, hit go, and sit back while they retire. My advice to you: Learn statistics and machine learning first, then worry about how to apply them to a given problem. There is no free lunch here. Data analysis is hard work . Read \"The Elements of Statistical Learning\" (the pdf is available for free on the website), and don't start trying to build a model until you understand at least the first 8 chapters...."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/3667/skewness-and-kurtosis-under-aggregation"}
{"id": "finance_3934", "domain": "finance", "question_title": "Portfolio optimisation with VaR or CVaR constraints using linear programming", "question_body": "I would like to optimize a portfolio allocation (maximizing the exposure or the expected return), but with VaR or CVaR contraints. (some parts of my portfolio cannot exceed a certain VaR) How can I achieve that? Is there a way to turn the problem into a linear programming problem? or to approximate the results? Any links or ideas are welcome.", "question_score": 23, "question_tags": ["portfolio-management", "portfolio-optimization", "optimization", "value-at-risk"], "choices": {"A": "In my experience, a VaR or CVaR portfolio optimization problem is usually best specified as minimizing the VaR or CVaR and then using a constraint for the expected return. As noted by Alexey, it is much better to use CVaR than VaR. The main benefit of a CVaR optimization is that it can be implemented as a linear programming problem. Another option I have tried is the technique in this paper: http://www.math.uwaterloo.ca/~tfcolema/articles/bank_article.pdf Another option is the two-step heuristic where one first finds the mean-variance efficient frontier and then you could calculate whatever are the relevant portfolio statistics on only the...", "B": "Garabedian, Typically, the \"swap curve\" refers to an x-y chart of par swap rates plotted against their time to maturity. This is typically called the \"par swap curve.\" Your second question, \"how it relates to the zero curve,\" is very complex in the post-crisis world. I think it's helpful to start the discussion with a government bond yield curve to clarify some concepts and terminologies. Consider the US Treasury market, using the outstanding Treasury notes and bonds (nearly 300 of them...), we can either use bootstrapping or more sophisticated spline models to construct a \"fitted curve.\" Since this yield curve...", "C": "I've worked at a hedge fund that allowed GA-derived strategies. For safety, it required that all models be submitted long before production to make sure that they still worked in the backtests. So there could be a delay of up to several months before a model would be allowed to run. It's also helpful to separate the sample universe; use a random half of the possible stocks for GA analysis and the other half for confirmation backtests.", "D": "This question goes to whether the historical returns to factors represent: Spurious results, overfitting, data mining... Mispricing Unexploitable effects Compensation for risk Case 1: Spurious results etc... If someone constructs a \"stock tickers that begin with AAP or GOO\" factor, the highly above average returns would almost certainly reflect a fishing expedition (or conditioning on future information) and would not be reproducible going forward. Under a null of no above average returns, you're going to get portfolios that have above average historical returns with t-stats over 2. Beware. For something like the Fama-French factor $\\mathit{HML}$, this seems far less likely..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/3934/portfolio-optimisation-with-var-or-cvar-constraints-using-linear-programming"}
{"id": "finance_27674", "domain": "finance", "question_title": "What is the most stable, non-trivial dependence structure in finance?", "question_body": "The highest rated answer to the question on What concepts are the most dangerous ones in quantitative finance work? is this one: Correlation Correlations are notoriously unstable in financial time series [...] My question My question is a little bit broader than just about linear dependence, it is: What is the most stable, non-trivial dependence structure in financial data? With non-trivial I mean that I don't want answers that are about direct connections, e.g. between derivative and underlying. The dependence structure can be either cross-sectional or through time with univariate time series, it can also be non-linear . The context of my question is that I am preparing the documentation for a new machine learning R package I wrote and I am looking for a good showcase in the financial sphere. Now this is not a trivial feat given that correlations are notoriously... see above ;-)", "question_score": 23, "question_tags": ["finance", "correlation", "dependence"], "choices": {"A": "It is hard to find a stable non-trivial dependence structure in financial data. Usually when such is found it is hard to rationalize. One of my favorite (although I am sure there are others) is the so called \"Presidential Puzzle\". This is an old finding by Santa-Clara and Valkanov (2003) They find that \" Excess return in the stock market is higher under Democratic than Republican presidencies: 9 percent for the value‐weighted and 16 percent for the equal‐weighted portfolio. At the time the finding was very robust and did not seem to be explained by anything else. What is more...", "B": "I would consider a motion chart that plots the eigenvalues of the covariance matrix over time. For a static view you can create a table: rows represent dates, and columns represent eigenvectors. The entries of the table represent changes in the angle of the eigenvector from the previous row. This will show how stable your covariance structure is. You can also create a second table this time with eigenvalues as the columns sorted from high to low (and the corresponding values below for each date). This shows the variance described by each eigenvector so you can see whether correlation as...", "C": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)", "D": "I have worked on this topic extensively (pricing and calculating IV in production) and believe can offer an informed opinion. First of all Mathworks - the company that creates Matlab is not a trading firm so you should probably not rely on their advice so much. There are few closed form options pricing models, and all have practical shortcomings. Barone-Adesi and Whaley (please correct my spelling of last names as I'm typing from memory) model is simple approximation for American options but is unfortunately not very accurate, and does not deal with dividends. Roll-Geske-Whaley deals with dividends, but not very..."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/27674/what-is-the-most-stable-non-trivial-dependence-structure-in-finance"}
{"id": "finance_34111", "domain": "finance", "question_title": "What are reasons not to do factor investing in equity markets?", "question_body": "Factor investing in equity markets is one of the hot topics of these days. Many manufacturers of investment products offer exposure to small cap, momentum, minvol, value and other pure factors or factor blends. Many of them beating the cap-weighted index at relatively low cost. I think of various reasons but I woud like to discuss: What are the reasons not everybody just invests in factor portfolios? What could be limitations, regulations, fears or other reasons not to invest in factor portfolios?", "question_score": 23, "question_tags": ["equities", "portfolio-management", "factor-investing"], "choices": {"A": "This question goes to whether the historical returns to factors represent: Spurious results, overfitting, data mining... Mispricing Unexploitable effects Compensation for risk Case 1: Spurious results etc... If someone constructs a \"stock tickers that begin with AAP or GOO\" factor, the highly above average returns would almost certainly reflect a fishing expedition (or conditioning on future information) and would not be reproducible going forward. Under a null of no above average returns, you're going to get portfolios that have above average historical returns with t-stats over 2. Beware. For something like the Fama-French factor $\\mathit{HML}$, this seems far less likely...", "B": "Have a look at this classic paper: Honey, I Shrunk the Sample Covariance Matrix by O. Ledoit and M. Wolf The abstract answers your question already: The central message of this article is that no one should use the sample covariance matrix for portfolio optimization. It is subject to estimation error of the kind most likely to perturb a mean-variance optimizer. Instead, a matrix can be obtained from the sample covariance matrix through a transformation called shrinkage. This tends to pull the most extreme coefficients toward more central values, systematically reducing estimation error when it matters most. Statistically, the challenge...", "C": "From what I remember, there is no real relation between Markov and Martingale, and my intuition was confirmed by this post . Basically, it says that you can say neither of the following: If A is Markov, then A is a martingale. If A is a martingale, then A is Markov. further down the post, you can find two counter examples: $dX_t = a dt + \\sigma dW_t$ is Markov but not a martingale and $dX_t = (\\int_0^t X_s ds) dW_t$ is a Martingale but is not Markov. As for the assumption of these properties being true, I think it...", "D": "I know that I have seen things like this in the past. Wasn't there something recently that used Twitter? Here are a few recent papers as examples, although I will be brutally honest that I don't know if they speak to your decent quality requirement: \"Trading Strategies to Exploit Blog and News Sentiment\" (Zhang, Skiena 2010) \"The Predictive Power of Financial Blogs\" (Frisbee 2010) \"An analysis of verbs in financial news articles and their impact on stock price\" (Schumaker 2010)"}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/34111/what-are-reasons-not-to-do-factor-investing-in-equity-markets"}
{"id": "finance_39619", "domain": "finance", "question_title": "Gamma Pnl vs Vega Pnl", "question_body": "Why does Gamma Pnl have exposure to realised volatility, but Vega Pnl only has exposure to implied volatility? I am confused as to why gamma pnl is affected (more) by IV and why vega pnl isnt affected (more) by RV? Essentially how do you show what gamma pnl will be mathematically and how do you show what vega pnl will be? I believe that gamma pnl is spot x (vega x IV - RV) Also does gamma pnl usually dominate (in $ terms) the vega pnl of an options, as most literature is on gamma pnl?", "question_score": 23, "question_tags": ["options", "implied-volatility", "option-strategies", "gamma", "vega"], "choices": {"A": "The risk-neutral measure $\\mathbb{Q}$ is a mathematical construct which stems from the law of one price , also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: \"there is no free lunch in financial markets\". This law is at the heart of securities' relative valuation , see this very nice paper by Emmanuel Derman (\"Metaphors, Models & Theories\", 2011) and some part of this discussion. In what follows, assume for the sake of simplicity existence of a risk-free asset ; deterministic and constant rates, with risk-free rate $r$ ;...", "B": "The volatiltiy surface is just a representation of European option prices as a function of strike and maturity in a different \"unit\" - namely implied volatility (while the term implied volatility has to be made precise by the model used to convert prices (quotes) into implied volatilities - for example: we may consider log-normal vols and normal vols). Volatility is often preferred over prices, e.g., when considering interpolations of European option prices (although this may introduce difficulties like arbitrage violations, see, e.g., http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1964634 ). A local volatility model can generate a perfect fit to the implied volatility surface via Dupire's...", "C": "For an option with price $C$ , the P $\\&$ L, with respect to changes of the underlying asset price $S$ and volatility $\\sigma$ , is given by \\begin{align*} P\\&L = \\delta \\Delta S + \\frac{1}{2}\\gamma (\\Delta S)^2 + \\nu \\Delta \\sigma, \\end{align*} where $\\delta$ , $\\gamma$ , and $\\nu$ are respectively the delta, gamma, and vega hedge ratios. Then it is clear the vega P $\\&$ L has exposure to the change of the implied volatility $\\sigma$ . Note that, for the gamma P $\\&$ L, \\begin{align*} \\frac{1}{2}\\gamma (\\Delta S)^2 = \\frac{1}{2}\\gamma S^2 \\frac{1}{\\Delta t}\\left(\\frac{\\Delta S}{S}\\right)^2\\Delta t, \\end{align*} where...", "D": "In general there are two basic ways to make money out of your option pricing models: Sell side (market maker, risk neutral): You use these models to calculate your greeks to hedge your portfolio, so that you live on the spread. Buy side (market/risk taker): You use your model to find mispriced options in the market and buy/sell accordingly. (A third possibility would be to write fancy books and papers about these models and get rich and/or tenure this way ;-)"}, "answer": "C", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/39619/gamma-pnl-vs-vega-pnl"}
{"id": "finance_180", "domain": "finance", "question_title": "How are distributions for tail risk measures estimated in practice?", "question_body": "Let's say you want to calculate a VaR for a portfolio of 1000 stocks. You're really only interested in the left tail, so do you use the whole set of returns to estimate mean, variance, skew, and shape (let's also assume a skewed generalized error distribution - SGED)? Or would you just use the left tail (let's say the bottom 10% of returns)? For some reason, using the whole set of returns seems more correct to me (by using only the left 10% or returns you'd really be approaching a non-parametric VaR). But using the whole set of returns would likely cause some distortion in the left tail in order to get a better fit elsewhere. How are the pros doing this? Thanks!", "question_score": 22, "question_tags": ["risk", "probability", "estimation", "value-at-risk", "expected-return"], "choices": {"A": "Perhaps you may want to consider article by D. Levine - Modeling Tail Behavior with Extreme Value Theory who gives practicale example on how EVT can be used to calculate probabilities on returns in tails with use of the Pickands-Balkema-de Haan Theorem and generalized Pareto distribution. It also contains some criterias and points on other methods that can be used to determine threshold value for PBH theorem: Contrary to this notion is the fact that the PBH theorem states a result based on the assumption of threshold values approaching the right endpoint of the distribution F. This implies that better...", "B": "Great question. We would expect 3rd party risk providers to have specialized expertise (robust regression techniques, factor research, data cleansing etc.). We might grant them these advantages but still find weakness in the product design. Let's start off with the different uses of risk models and the procedure or metric which is maximized to solve for that use case. What we will see is that solving for a particular objective diminishes our ability to achieve other objectives. Portfolio construction = If you want to construct a minimum variance portfolio, for example, then the key here is developing a covariance matrix...", "C": "One starts with the Black-Scholes equation $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2S^2\\frac{\\partial^2 C}{\\partial S^2}+ rS\\frac{\\partial C}{\\partial S}-rC=0,\\qquad\\qquad\\qquad\\qquad\\qquad(1)$$ supplemented with the terminal and boundary conditions (in the case of a European call) $$C(S,T)=\\max(S-K,0),\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad(2)$$ $$C(0,t)=0,\\qquad C(S,t)\\sim S\\ \\mbox{ as } S\\to\\infty.\\qquad\\qquad\\qquad\\qquad\\qquad\\qquad$$ The option value $C(S,t)$ is defined over the domain $0 Step 1. The equation can be rewritten in the equivalent form $$\\frac{\\partial C}{\\partial t}+\\frac{1}{2}\\sigma^2\\left(S\\frac{\\partial }{\\partial S}\\right)^2C+\\left(r-\\frac{1}{2}\\sigma^2\\right)S\\frac{\\partial C}{\\partial S}-rC=0.$$ The change of independent variables $$S=e^y,\\qquad t=T-\\tau$$ results in $$S\\frac{\\partial }{\\partial S}\\to\\frac{\\partial}{\\partial y},\\qquad \\frac{\\partial}{\\partial t}\\to - \\frac{\\partial}{\\partial \\tau},$$ so one gets the constant coefficient equation $$\\frac{\\partial C}{\\partial \\tau}-\\frac{1}{2}\\sigma^2\\frac{\\partial^2 C}{\\partial y^2}-\\left(r-\\frac{1}{2}\\sigma^2\\right)\\frac{\\partial C}{\\partial y}+rC=0.\\qquad\\qquad\\qquad(3)$$ Step 2. If we...", "D": "Nick Higham's specialty is algorithms to find the nearest correlation matrix. His older work involved increased performance (in order-of-convergence terms) of techniques that successively projected a nearly-positive-semi-definite matrix onto the positive semidefinite space. Perhaps even more interesting, from the practitioner point of view, is his extension to the case of correlation matrices with factor model structures. The best place to look for this work is probably the PhD thesis paper by his doctoral student Ruediger Borsdorf. Higham's blog entry covers his work up to 2013 pretty well."}, "answer": "A", "distractor_source": "same_domain_answer_pool", "source": "stackexchange", "license": "CC-BY-SA 4.0", "url": "https://quant.stackexchange.com/questions/180/how-are-distributions-for-tail-risk-measures-estimated-in-practice"}