MACD Synthetic Conformance Test (B048)

Category: momentum

This is a conformance test script validating the ta.macd implementation against a deterministic synthetic data generator. It calculates the MACD histogram for both continuous and gapped (NaN-injected) synthetic source series.

Formula

\text{MACD Line} = \text{EMA}(src, 12) - \text{EMA}(src, 26) \\ \text{Signal Line} = \text{EMA}(\text{MACD Line}, 9) \\ \text{Histogram} = \text{MACD Line} - \text{Signal Line} \text{ where } src \text{ is a synthetic LCG-generated series.}

See signal primitives, usage in published strategies and more on WOBR StrategyVerse.


Open in the WOBR AI app → · WOBR.AI home