This template trades crossovers between a fast and a slow exponential moving average, with configurable lengths and an optional filter based on the direction of a longer simple moving average. A bullish crossover can open a long when the filter is rising; 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
9,660 documents
This example strategy combines bullish and bearish fair value gaps with MACD crossovers filtered by RSI. It also defines trend-aligned flags using the relationship between price and a moving average, together with above-average volume. Entries require one of…
This strategy builds a fixed grid between user-selected lower and upper prices, using either equal price intervals or equal percentage intervals. It submits buy limit orders at grid levels and links each entry to a take-profit order at the next level above.…
This script describes an intraday VWAP strategy centered on the NYSE regular-session open. It includes a 09:45–11:00 New York trade window, VWAPs anchored to different session starts, prior-day VWAP, opening-range and initial-balance levels, and a status…
This strategy defines an opening box during a selected market session, using that period's high and low as breakout boundaries. It seeks one qualified break per box, then a first retest and directional confirmation before entering, with an option for direct…
This TradingView strategy runs a long-only price grid between user-set upper and lower bounds. It divides the allocated investment evenly among grid levels, with either geometric spacing, which keeps percentage gaps more consistent, or arithmetic spacing,…
This strategy trades breaks of market structure, using break-of-structure (BOS) and change-of-character (CHoCH) signals to identify potential entries. A configurable pivot lookback finds swing levels, with an option to scale the lookback for higher…
This automated strategy looks for bearish shooting-star candles during a configurable weekday session. A signal requires the bar to make a higher high than the prior bar and close, along with its open, in the lower portion of its range. Optional filters…
This intraday strategy trades only within a configurable opening window and seeks long or short entries around the prior day’s high or low and the premarket high or low. Setups include a level retest, a first confirmed touch, or a pullback to the fast EMA.…
This strategy looks for a wick imbalance in the previous candle, requiring its combined upper and lower wicks to exceed the prior ATR and its real body to meet a minimum ATR-based size. A dominant upper wick produces a long signal, while a dominant lower…
This simple strategy counts consecutive closes that rise or fall. Reaching the configured count submits a long or short strategy entry, respectively, and sends an alert at bar close. The accompanying explanation describes forwarding those alerts through a…
This Pine strategy template supplies the execution and risk-management framework for a separately defined trading signal. It accepts an external indicator source, interpreting values as long or short entries and optionally as custom exits. Inputs govern…
This indicator estimates trading costs and liquidity conditions from bar data rather than order-book or trade-level observations. It combines several spread estimators, including Roll’s price-change covariance, Corwin–Schultz’s two-period high-low method,…
This MNQ strategy defines the opening range from the first 15-minute bar beginning at 9:30 a.m. New York time and tracks the overnight high and low from 6:00 p.m. through 9:29 a.m. It arms a direction when a candle closes beyond the opening range and, by…
This strategy places limit orders at the prior bar’s VWAP while using the previous close relative to that VWAP to select long or short direction. The limit level updates as new bars form, creating a rolling entry reference. Inputs let users enable either…
This simple rule takes a long position when the current bar opens above the previous bar's open and a short position when it opens below it. The script uses a trailing exit and configures orders at a percentage of equity, with commission included in its…
This SPY intraday strategy uses crossovers between 5-period and 9-period simple moving averages to signal long and short entries. It requires current volume to exceed the prior bar’s volume and restricts new entries to a morning window from 9:32 to 11:12…
This XAUUSD scalping strategy combines an ATR-based trailing stop crossover with several confirmation filters. It requires alignment between fast and slow exponential averages on the chart timeframe and a higher timeframe, sufficient ADX, matching SuperTrend…
This Pine library implements a collection of moving averages and related filters, emphasizing constant-time updates, numerical stability, optional reset anchors, and support for fractional or effectively unbounded lengths. Its documented functions include…
This chart indicator displays a digital and analog clock for a selected city or exchange time zone. It offers a broad set of locations and uses IANA time zones, with daylight saving changes handled automatically. The clock is intended to help traders read…
This short-term strategy uses crossovers between a 5-period and a 13-period exponential moving average to trigger long and short entries. On entry, it places a stop at a fixed percentage from the signal-bar close and specifies a trailing distance based on…
Focus Bars uses lower-timeframe data to break recent chart candles into configurable price rows. It estimates directional participation from intrabar price movement, distributes that activity across the prices traversed, and displays buy-side and sell-side…
This script trades crossovers between fast and slow exponential moving averages, entering long on an upward cross and short on a downward cross. Trades can be restricted to the 15-minute chart and weekdays. It sizes entries at the configured full-equity…
This short-term strategy seeks momentum reversals using Heikin-Ashi candle structure. A setup requires a preceding candle of the opposite color, followed by three same-direction candles with no wick on the entry side; each candle body must be larger than the…