Signals Overview
Signals are the building blocks of automated trading strategies in Mangrove. Each signal is a boolean function that evaluates a market condition against OHLCV (Open, High, Low, Close, Volume) data and returnsTrue or False.
Signals are stateless: they receive a DataFrame of historical price data, run
a technical indicator calculation, compare the result to a threshold or pattern,
and return a boolean. They do not maintain internal state between evaluations.
Signal Types
Every signal is classified as either a TRIGGER or a FILTER.TRIGGER
A TRIGGER signal fires on a specific event — the exact bar where a condition transitions from false to true. Triggers detect crossovers, breakouts, reversals, and other discrete transitions. Examples:sma_cross_up— fires when the fast SMA crosses above the slow SMAbb_upper_breakout— fires when price crosses above the upper Bollinger Bandmacd_bullish_cross— fires when the MACD line crosses above the signal line
True only on the bar where the event occurs. On subsequent
bars where the condition remains true, they return False.
FILTER
A FILTER signal evaluates a continuous condition — whether the market is currently in a particular state. Filters confirm trend direction, momentum levels, volatility regimes, and volume conditions. Examples:rsi_overbought— true whenever RSI is above the overbought thresholdadx_strong_trend— true whenever ADX indicates a strong trendvwap_above— true whenever price is above the VWAP
True on every bar where the condition holds.
Why the distinction matters
Strategies use TRIGGERS to decide when to enter or exit, and FILTERS to decide whether conditions are favorable. A trigger fires an event; a filter gates it.Strategy Composition
A strategy is composed of one or more entry blocks and exit blocks. Each block contains:- 1 TRIGGER signal — the event that initiates the action
- 1 FILTER signal — the condition that must also be true
True and the FILTER
returns True on the same bar.
Required Data Columns
Every signal declares which OHLCV columns it requires. The platform validates that the provided DataFrame contains these columns before evaluation.| Column | Description |
|---|---|
Close | Closing price. Required by virtually all signals. |
High | Highest price in the bar. Required by signals using range-based indicators (ATR, Stochastic, Bollinger Bands, etc.). |
Low | Lowest price in the bar. Required alongside High for range-based indicators. |
Volume | Trading volume. Required by volume-based signals (OBV, MFI, VWAP, CMF, etc.). |
Close. Volatility signals
typically require High, Low, and Close. Volume signals add Volume
to their requirements.
Signal Parameters
Each signal accepts configurable parameters with documented ranges and defaults. For example,rsi_overbought accepts:
| Parameter | Type | Range | Default | Description |
|---|---|---|---|---|
window | int | 2-100 | 14 | RSI calculation window |
threshold | float | 50-100 | 70.0 | Overbought threshold |
Using Signals
Python (direct)
REST API
Listing available signals
Signal Categories
Signals are organized into six categories based on the underlying indicator type:| Category | Count | Focus |
|---|---|---|
| Momentum | 42 | RSI, Stochastic, Williams %R, TSI, KAMA, ROC, Awesome Oscillator, StochRSI, PPO, PVO, MOM, BOP, APO, CMO |
| Trend | 88 | SMA, EMA, WMA, MACD, ADX, Aroon, Ichimoku, PSAR, Vortex, DEMA, TEMA, HMA, ALMA, T3, MAMA, SuperTrend, Alligator, HeikinAshi, MARibbon, Divergence |
| Volume | 33 | OBV, CMF, MFI, VWAP, ADI, Force Index, NVI, EOM, VPT, VWMA, ADOSC, KVO |
| Volatility | 20 | Bollinger Bands, ATR, Keltner Channel, Donchian Channel, Ulcer Index, NATR, STARC Bands, ATR Trailing Stop, TTM Squeeze |
| Patterns | 40 | Candlestick patterns (engulfing, hammer, doji, stars) and multi-bar pattern recognition |
| On-Chain | 10 | Exchange netflow, smart-money flows, whale accumulation, holder concentration (consumes alternative-data columns alongside OHLCV) |
Scope & limitations
The categories above describe what the library can express. Signals are stateless functions over OHLCV bars (plus, for On-Chain signals, the alternative-data columns the caller supplies) — they carry no clock, calendar, or session context, and they do not model market-microstructure constructs. A few popular trading frameworks are therefore not currently available as built-in signals:| Not currently in the library | Why / closest in-library proxy |
|---|---|
| Session / time-of-day filters — London open, New York open, Asian session, etc. | Signals evaluate purely on bars and carry no time-of-day context, so a session window cannot be expressed. No proxy reproduces a calendar window. |
| ICT / Smart Money Concepts — Fair Value Gap (FVG), Order Block, Breaker Block, liquidity sweeps | Not implemented. For an institutional-reference price use vwap_above / vwap_below; for directional bias use adx_strong_trend or a moving-average filter such as is_above_sma; for price-action structure browse the Patterns category (engulfing, pin bar, inside/outside bar, …). These approximate the intent but are not the same constructs. |