Ema start time1/17/2024 ![]() This is an average that tracks price closer than the TWAP like moving average explained under (2). Starting again with Close., the value for the second bar would be 1/3 * Close + 2/3 * Close, the value for the third bar would be 1/6 * Close + 1/3 * Close + 1/2 * Close, the fourth bar 1/10 * Close + 1/5 * Close + 3/10 * Close + 2/5 * Close etc. (3) If we do not use Wilder's smoothing, but use the habitual smoothing alpha = 2/(n+1), then the result would look slightly different. ![]() Used on minute bars we obtain our anchored time- weighted average price (TWAP). This would be in fact the same result that we get, if we use a SMA with an increasing period. For the first value we would get the Close, for the second bar 1/2*(Close + Close), for the third bar 2/3 * 1/2 (Close + Close) + 1/3 * Close = 1/3(Close + Close + Close) etc. If we take Wilder's smoothing we obtain alpha = 1/n. (2) You could also use a second concept and increase the period of the EMA with each bar. There is not one such EMA that can be constructed from a high point or low point, but there is a whole collection of EMAs that can be built by using this method. The inconvenience of this approach is that the outcome depends on the selected period. After some time this EMA would converge to the regular EMA(15). For the anchor bar the EMA would show the close of the anchor bar, the second and all consecutive values can be calculated as 0.875*Close + 0.125*Close. You would start with the close of the anchor point (high bar or low bar) and then calculate the following values by using the smoothing constant alpha = 2/(n+1) = 1/8. (1) The first one is to use a fixed period for the EMA. In your example are you looking to plot an EMA with a period of 84, and only show the EMA starting from the first bar in the series? Or, is it an EMA with a period of X to start plotting Y bars back, where X does not equal Y? And, do you want the starting bar to be a certain number of bars back or based on a starting time, like 3pm? I'm not sure I quite understand what you're looking for. ![]() The SMA is a FIR filter and your idea would promote it to a TWAP on a time-based chart. You can recognize a FIR filter, as it does not use any recursive formulae, or explained in a different way, it does not use any of its prior value in the calculation for the current values. If you wish to take the MIDAS idea and use it with other moving averages this is also possible, as long as you apply it to finite impulse response (FIR) filters. This would create a MIDAS variation that lets drop out part of the old information. ![]() Your concept can be implemented, you can also use a volume-weighted EMA with a large period. You can therefore create a specific anchored EMA for any bar on your chart. The EMA is an exception as it only uses its value one bar ago. In general IIR filters have training periods during which they do not show accurate results. The EMA is an infinite impulse response (IIR) filter, and it is therefore influenced by all of its prior values. Would look something like subterfuge: Funny you selected an EMA to start with. So, if I was to take Fridays' CL chart, and decide I wanted my ema to begin from, 3pm, or 84 bars away, it I want a moving average indicator where I choose what bar the the indicator begins from. I have a feeling that my idea has already been done on here (but I can't seem to find it), so i'm hoping someoneĬan link me too it (assuming i'm correct) ![]()
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |