2
$\begingroup$

I am trying to understand something:

If I calculate an EMA over 5 days, using the hourly close, I have to go over 5 * 24 points.

If I calculate an EMA over 5 days, using the minutes close, I have to go over 5 * 60 * 24 points.

Obviously, the 'close' value is very arbitrary and the hourly data may miss a lot of of things.

What surprised me is that when I plot EMAs, in TradingView, over the same time period, but with a very different resolution as described above, the output is very different, up to 20% in the last few days.

Is it the extra data, in the minutes resolution, responsible for this?

In that light, shouldn't the high resolution data be more useful as more 'true' to the real signal? (with the assumption that using 'close' values is arbitrary and may miss a lot of important moments.

$\endgroup$
  • $\begingroup$ HI: I would not use EWMA through different days because the close of one day is "too different" from the opening of the next. Atleast AFAIK, the EWMA is used for discrete case where the data is "continuous" in the sense of not being stopped and started and stopped and started etc. $\endgroup$ – mark leeds Oct 5 '19 at 13:32
  • $\begingroup$ so it makes sense to stick to one 'resolution' (day, hour or minutes) and do all calculations from the same resolution? that would mean that a day ema calculated in minutes would be a long calculation $\endgroup$ – Thomas Oct 5 '19 at 13:33
  • $\begingroup$ Hi: Not clear on the question but ewma assumes that you have one continuous ( not continuous in the sense of continuous versus discrete. continuous in the sense of time not being skipped ). So, it doesn't matter what units you consider but you can't "skip". So, if you use minutes, don't use the next day because things happen between there that kind of make the price dis-continuous. days or weeks or months are okay. but minutes are too fine to justify using the next day as a continuation. Also, better to use returns.. EWMA assumes a constant mean and prices don't satisfy that assumption. $\endgroup$ – mark leeds Oct 6 '19 at 13:20
  • $\begingroup$ ok, so you mean the EWMA is not a good fit for analyzing minutes because there is too much dis-continuities in the prices? I'm not a trader, I'm tasked to transcribe in code a trader's fuzzy non mathematical mind right now, so there is a lot of chaos :) learning a lot through the process though. My understanding is that the hourly close values are missing out important bits since the close value is completely arbitrary; it is not more meaningful than minute 37 for example. $\endgroup$ – Thomas Oct 6 '19 at 16:53
  • 1
    $\begingroup$ Hi: Yes. I think you understand what I mean by why the EWMA shouldn't be carried over to the next day. Prices are usually EXTREMELY non-stationary because they trend. Returns, which can be viewed as difference of log prices, usually don't exhibit trend so are atleast closer to being stationary compared to prices. So, generally speaking, returns are used when trying to forecast prices in the future. Note that, if you know the current price and you forecast the return, then you can always back out the predicted price. But don't predict it directly. $\endgroup$ – mark leeds Oct 8 '19 at 1:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.