This discussion examines how starting portfolio composition can distort a simple account-value profit calculation for a cryptocurrency strategy. It compares two accounts following the same price move: one begins with a bitcoin and no cash, while the other…
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
This documentation explains how Lumibot represents cash flows separately from trading activity in strategy backtests and live broker data. It distinguishes deposits and withdrawals from performance while accounting for financing, dividends, fees, interest,…
The document explains how crypto data aggregators combine information from centralized and decentralized exchanges into normalized time series. It frames fragmentation across venues, trading pairs, and blockchains as an infrastructure problem for…
This screening rule selects Chinese stocks with turnover between 3% and 12% and year-over-year growth in net profit attributable to the parent company above 20% and up to 100%. It then ranks qualifying stocks by the day’s auction amount and chooses the first…
This stock screen combines a turnover range of 3% to 12% with year-over-year growth in net profit attributable to the parent company above 20% and up to 100%. It also requires the KDJ K value to be rising, using a prior-period comparison. The article…
This Backtrader example pairs a simple moving average crossover strategy with two sizing approaches. The strategy buys when price crosses above a 15-period simple moving average and sells when it crosses below. A long-only sizer submits a fixed stake for…
This post proposes a technical screen for Chinese A-share stocks. It selects shares with RSI below 65, seven consecutive sessions in which the close is no higher than the open, and a KDJ stochastic K reading below 20. The accompanying code sketch describes…
This brief VeighNa forum exchange asks how to adjust bar construction for the morning futures market break from 10:15 to 10:30. A respondent explains that the BarGenerator currently divides data according to timestamps and asks which kind of bar the user…
This stock-selection proposal targets main-board shares associated with robotics. It filters for turnover between three and twelve percent, circulating market value below 10 billion yuan, and a weekly five-period moving average crossing above the ten-period…
This indicator adapts the Hull moving average by using a fast exponential moving average in its calculation. The standard Hull method combines weighted moving averages over different periods and applies a smoothing step based on the square root of the…
This bot aims to mirror a named member of Congress’s reported stock holdings. A research agent checks House disclosure filings, using annual reports as the starting portfolio and applying later trade reports to update it. It excludes options, real estate,…
This note outlines a chart-based stock screen using at least five converging moving averages, a rounded or arc-shaped price pattern, and a focus on stocks associated with 2021. It illustrates possible moving-average periods of 5, 10, 20, 50, and 200 days,…
This document describes an expert advisor that trades changes in the direction color of a PercentageCrossover indicator. It generates a signal when a bar closes and the indicator changes direction, then allows trades to be restricted to a configurable daily…
This report reviews factor performance across the broad market, sectors, industries, and indices during the first half of 2018, then examines factor selection in a market with sharply different outcomes across stocks and sectors. It reports that most factors…
This summary describes a market-timing approach that uses a convolutional neural network to extract patterns from lower-dimensional index features, including technical indicators, and classify expected returns. Predicted return classes are then used to drive…
The document answers how to identify when a strategy’s maximum drawdown occurred in a backtest. It recommends adding a strategy risk overview module after the backtest module, which reports the drawdown and its associated date. The example reports a maximum…
This report summary examines whether northbound capital flows into mainland Chinese equities can inform market timing and portfolio selection. It describes threshold signals for daily and weekly flows, then a dynamically adjusted timing indicator. It also…
This hourly long-only strategy combines the Average Directional Index (ADX) with two simple moving averages. It calculates a 14-period ADX and 3-period and 6-period SMAs. A long entry is signaled when ADX is above 25 and the shorter SMA crosses above the…
This QlibRL example describes how to configure and run a reinforcement learning workflow for executing orders in one asset. The training setup defines a simulator with 30-minute steps, a categorical action space, a full-history state representation, a…
This guide explains FMZ’s simulated-tick and real-tick backtesting modes. Simulated ticks are generated from candlestick data, while real-tick mode replays recorded tick data and can include depth and trade records. The guide describes the trade-off between…
This Expert Advisor trades when the ColorZeroLagTriX indicator cloud changes color. It forms a signal at bar close when the oscillator crosses its signal line, making the method dependent on a confirmed closing-bar crossover rather than an intrabar move. The…
This document describes an Expert Advisor that combines two independent trading systems based on the Skyscraper_Fix and ColorAML indicators. It generates a signal when a bar closes and either indicator changes color, which the document treats as a change in…
The document describes a stock selection rule that filters for turnover between 3% and 12%, companies listed in 2021, and an observation at 9:25 with a price increase below 6%. It presents the screen as a way to refine entry timing and avoid buying after a…
The article explains Active Fundamental Performance (AFP), a measure intended to identify mutual fund managers who select stocks well on fundamental information. For each fund, it computes the covariance between benchmark-adjusted portfolio weights, or…