Thanks mrtools.
I did a quick comparison against the MT4 QQE vs MT5 QQE and there seem to be differences in the calculation. The dotted line in the MT4 version stays horizontal but the MT5 version angles downwards. Is there anyway to double check the codes?
See screenshots for example.