CDLMATHOLD
CDLMATHOLD
Summary
A five-candle bullish continuation pattern: a long white candle, an upside real-body-gapped small black candle, two more small falling candles that hold within the first body, and a final white candle closing above the reaction days' highs. Signals continuation of the prior uptrend. Hit = bullish continuation of the existing uptrend.
Notes
- The colors of the third and fourth (reaction) candles are not checked, although they are classically black.
- The continuation reading assumes a prior uptrend, which is not verified.
Inputs
inOpen— Open price of each barinHigh— High price of each barinLow— Low price of each barinClose— Close price of each bar
Outputs
outInteger— +100 when the bullish Mat Hold is detected, 0 otherwise. Never emits -100
Parameters
| Parameter | Type | Default | Accepted values | Description |
|---|---|---|---|---|
optInPenetration | real | 0.5 | ≥ 0 | Max fraction of the 1st white body the reaction days (3rd, 4th) may penetrate |
Properties
Numerical Stability: Start-Independent
| Display Flags |
|---|
| ☐ Overlap Input |
| ✅ Independent Y-Axis i |
| ✅ Candlestick i |
Implementation
TA-Lib Definition: cdlmathold.c · cdlmathold.yaml
| Native | File |
|---|---|
| C | ta_CDLMATHOLD.c |
| Rust | cdlmathold.rs |
| Java | Core_CDLMATHOLD.java |
TA-Lib is also available for Python, R and more using a wrapper.
Aliases
Mat Hold