This discussion describes a backtest problem caused by missing historical prices in a rolling maximum calculation. The author expected the portfolio to hold ten stocks, but in earlier periods it sometimes held only one or two. The suspected cause was that a…
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
21,023 documents
The document proposes using convex optimization to model how farmers allocate limited arable land among crops to maximize profit. Its framework combines crop prices, production costs, and supply effects: planting more can raise output but may also depress…
This indicator adapts the Commodity Channel Index lookback period to an estimated market cycle. It first smooths price data and uses phase and quadrature components with a homodyne discriminator to estimate cycle length. That estimate is constrained to a…
This stock selection rule screens for turnover between 3% and 12%, an opening price within 5% of the ten-day simple moving average, and circulating market capitalization above 10 billion yuan. The document frames turnover as a measure of trading activity,…
The document outlines NautilusTrader’s architecture for defining custom data in Python or same-binary Rust, then routing and persisting it through common runtime interfaces. Both approaches use a shared outer CustomData wrapper and DataType identity. Runtime…
This forum exchange explains why a futures backtest can differ from a course example even when the strategy and settings are the same: the data series may be revised over time. It describes the platform’s 888 series as a continuously smoothed main-contract…
The article investigates why MACD values from TradingView and FMZ differ despite matching results across several FMZ indicator implementations. To isolate the discrepancy, the author compares EMA values and writes a manual EMA calculation, which agrees with…
The document identifies the fitness-function setting used by a genetic programming module and lists its available objectives. These include information coefficient to information coefficient ratio, mutual information, long-only Sharpe, volatility and return…
This document summarizes research on how investment fund flows relate to fund performance and asset growth. It reports that international studies generally find a positive association between performance and inflows, with a nonlinear relationship to…
This document describes an analytical method for choosing entry and exit levels in a statistical arbitrage strategy whose log price follows an exponential Ornstein–Uhlenbeck process. The trade cycle runs from an entry level to an exit level and back to the…
This forum post asks how to understand two approaches to adapting factors to market style. For a W-style split, the author proposes dividing a factor using a reference variable such as trading amount and treating the difference between the resulting groups…
This post describes a Chinese equity factor inspired by a research report. Its volume component divides the trading session into five-minute intervals, measures each stock’s share of market volume, and uses Shannon entropy to characterize how that activity…
The document explains an indicator that reports compound annual growth rate (CAGR) and total percentage growth between an asset’s first and latest available closing prices. CAGR annualizes the change using the elapsed period count, while the growth rate…
This indicator combines swing-point fractals with selected bar counts drawn from Ichimoku number theory. It identifies an initial swing high or low using a configurable fractal shoulder, then tracks up to two further swing points and marks the specified…
This example queries Chinese stock valuation data for a specified date and examines the distribution of total market capitalization. It trims observations below the second percentile and above the ninety-eighth percentile, divides the remaining values into…
The document describes a script that exports values from built-in MQL5 indicators to a CSV dataset for analysis. It identifies several indicator buffers, including the center and outer Bollinger Bands, ADX lines, MACD and signal lines, RVI, Stochastic, tick…
This article proposes selecting stocks using three activity-related conditions: a price amplitude above a threshold, actual turnover within a specified band on the previous day, and positive auction-period turnover above a threshold. It frames the added…
The indicator uses the slope of a linear regression on closing prices as a measure of trend direction and intensity. It proposes testing whether the slope differs statistically from zero: a slope not distinguishable from zero is treated as a sideways market,…
This Chinese stock-selection post combines three market-data conditions: amplitude above one, large-order net volume above 0.05 for at least three consecutive days, and a current low below the prior day’s low. It presents the screen as a way to combine price…
This reference explains how information theory can measure dependence between variables, including asset returns. It introduces entropy as uncertainty, then defines mutual information as the reduction in uncertainty about one variable from observing another.…
This survey reports how U.S. crypto holders perceive tax complexity and how tax concerns influence their investment choices. Respondents commonly expressed concern about effects on returns, confusion over reporting, rates, staking, and rewards, and…
The document introduces file handling in MQL as a way to write price values to local storage. It identifies a file-based trade copier as one possible application, where a program can save information for another process to access. It also describes using…
The post proposes screening stocks using price movement and trading activity around the opening auction. Its stated rule selects shares with amplitude above a threshold, yesterday's turnover rate multiplied by today's auction volume relative to yesterday's…
This short note shows how to flag two three-candle formations: three white soldiers and three black crows. The detection rules check that each candle in the sequence closes above or below its open, respectively, and that the closes move progressively upward…