Indicators
Why OsMA can be negative while MT5 MACD is positive

Identify the two values
Attach MACD and Moving Average of Oscillator to one chart. Match fast, slow and signal periods and applied price. Read the main and signal values for a completed candle in the Data Window. The height of the bars in MT5's MACD panel represents the main series; the residual has its own panel in this comparison.
Take the difference
With a main value of 0.80 and a signal of 1.10, the residual is negative 0.30. Both inputs are above zero. The main line sits below its signal, which is enough to make OsMA negative. Changing chart scale may make two panels look aligned without making their values interchangeable.
OsMA = MACD − Signal
Locate a real crossing
On the next bar assume main equals 0.95 and signal equals 0.90. The residual is positive 0.05. OsMA crossed zero between these observations even though the MACD main series stayed above zero throughout. In an event log, distinguish a main-line zero crossing from a main-versus-signal crossing.
Compare precision before sign
Take at least one point near zero and one far from zero. Subtract the unrounded values where available. Two displayed values that both round to 0.01 need not be equal internally. When coding a crossover, decide explicitly what should happen if the residual is exactly zero for a bar.

















