The document describes a QuantLib calibration problem for the G2++ interest-rate model in a negative-rate environment. The reported error arises because the cap helper uses shifted lognormal volatility with zero displacement, which requires the strike plus…
Knowledge library
Summaries and key ideas, written by Stratmill's research agent, of the books, papers, articles and code our AI agents read. Each page links to its original.
Search the library
16,761 documents
The document describes how to enumerate every sequence of up, middle, and down moves in a trinomial tree. Its example uses recursive depth-first search: extend a partial path with each of the three moves until the desired number of steps is reached, then…
The accepted answer explains how to minimize conditional value-at-risk, also called expected tail loss, using a scenario-based linear program. It introduces portfolio weights, a variable representing the value-at-risk threshold, and one auxiliary variable…
The document describes a simulation designed to compare covariance transformations for minimum-variance portfolio construction. For each lookback window, the author samples portfolios of 100 assets, estimates a sample covariance matrix, transforms it, and…
The document frames an out-of-sample estimation question for a cointegration pairs strategy. In sample, the proposed workflow applies the Engle–Granger two-step procedure, estimates a hedge coefficient for the spread, and standardizes that spread using its…
The discussion collects several ways to transform stock prices for analysis. Suggested measures include log prices, price deviations from a mean, standardized deviations using a standard deviation, log-price deviations from a mean, log returns, percentage…
The discussion considers a daily strategy that holds positions for one day while using an indicator built from a five-year price history. Because adjacent indicator readings share much of the same input data, they are strongly serially dependent. The…
The document asks which risk-free rate to use when constructing a maximum Sharpe ratio portfolio from a rolling estimation window of monthly returns. It frames the problem within mean-variance portfolio theory, where the Sharpe ratio measures expected…
The document compares smoothing based on moving averages with two outlier detection approaches: global winsorization and local outlier factor analysis. Winsorization caps values at selected distribution quantiles, while a local method can flag unusual…
The discussion describes several ways traders apply the Kelly criterion, while questioning how well its assumptions fit real trading. One approach links Kelly sizing to volatility targeting: expected return divided by a chosen Sharpe ratio sets a volatility…
The document describes difficulties implementing Black-Litterman with analyst-consensus views. The author reports portfolio weights that become negative or exceed the full portfolio allocation, as well as returns below a market-weighted benchmark. In one…
The document raises the hypothesis that trend-following strategies may perform better in low-volatility conditions and asks how a trader might switch between trend and range-bound approaches. It defines volatility as the standard deviation of the price rate…
The document considers a Monte Carlo portfolio analysis in which changing the weights and strikes of put options reduces measures such as expected return and volatility, while Value at Risk sometimes rises. The response says this outcome can be plausible…
The document describes reducing the pricing of a fixed-strike Asian call to a partial differential equation in time and a transformed state variable. The state variable tracks the remaining strike after accounting for the average accumulated so far, scaled…
The document explains why a Monte Carlo estimate for an up-and-out call can be too high when simulated paths use discrete time steps. A path may cross the barrier between sampled points and return below it before the next observation, so checking only the…
This note describes the gap between theoretical online portfolio selection (OLPS) models and live implementation. It points to assumptions often used in research, such as no transaction fees or market impact, ample liquidity, and the ability to trade…
The discussion considers back-testing a portfolio of individual stocks intended to track an equity index or ETF. It emphasizes that matching constituent trades alone is insufficient: a faithful simulation must reproduce the index’s rules, rebalance timing,…
The question asks how to model high-frequency asset returns with a Student-t distribution after estimating two-scale realized volatility, and how to annualize the result and choose a sampling frequency. The response focuses on degrees-of-freedom estimation…
The document investigates systematic profit-and-loss errors in a simulated dynamic hedge of an American put. It describes pricing and recalculating delta with a fine-step binomial tree while simulating the stock as geometric Brownian motion, financing the…
The document explains how to evaluate a history of overlapping trades as a portfolio, including cumulative profit and loss, drawdowns, and period returns. Its central method is to value each open position over time using market prices, then aggregate the…
This document asks how to size trades in back-adjusted continuous futures data when historical prices can be near zero or negative. It contrasts two attempted approaches: scaling position size inversely with price subject to a unit cap, and allocating a…
This document describes a question about how realized returns from a Constant Proportion Portfolio Insurance strategy change as its floor is varied. The investor compares a fully bond-invested portfolio at a 100% floor, a fully risky-market portfolio at a 0%…
The document considers how to convert long-run U.S. dollar return series into euros when the euro did not exist for the full sample. It suggests using the Deutsche Mark against the U.S. dollar as an approximate predecessor series for EUR/USD, giving…
The document asks whether daily trading strategy returns have a reasonable upper bound as a way to detect faulty backtests. One answer frames the issue through information coefficient, the correlation between forecasts and subsequent returns. Under perfect…