Jump to content

How is intraday Moving Average calculated? How the moving average line changes when chart scale changes?

Guest CowboyJJ

Recommended Posts

Guest CowboyJJ

I am probably asking a very dumb question here but I just can't find the answer I am looking on Google ( and I really can't believe that).

Let's take 5 day moving average for example.

We all know its official definition is the average of the closing prices of the last 5 five days. But in reality it isn't, right?

For example, when I look at the live chart of any stock, clearly the 5DMA line is updated as new prices trickle in. So, doesn't that mean the formula of live 5DMA should be (live  price + previous 4 days' closing prices)/5? Or is it ? Can anybody clarify exactly how the live 5DMA line is calculated?

Second question: The 5DMA line changes when the scale of the price chart changes. For instance, the 5DMA line on a 6M chart is clearly not the same 5DMA line on a 5D chart. And I don't think it's just a matter of granularity. Why? How is the line calculated differently when the chart scale changes? To me, it seems that when the scale of the price chart changes from 1D to 1M, the moving average line changes from 5-day average to 5-Month moving average. Or am I wrong?

Anybody who knows please help! Because I just can't make sense them!



Link to comment

Hi @CowboyJJ,  your last sentence about changing with time scale is correct. The 5 day moving average can only apply to a daily chart, if you change the time frame to the hourly chart it becomes the 5 hour moving average.

The 5 day moving average is the average from the previous 5 days and plotted on today's candle, day six. It won't move during the day as day six prices change and will only change on day 7 when day 6 becomes the last of the 5 days used for the calculation, the 5 hourly moving average will only change every hour. 

Link to comment
Guest CowboyJJ

Hi @Caseynotes, thanks for such a quick reply! Also thanks for confirming my suspicion with regard to my second question.

With regard to my first question I'm afraid I have to disagree with you due to two observations:

1. If what you said were correct, the 5DMA line (or any moving average lines) would have been piece-wise constant. Yet they are not. They are all smooth lines.

2. In fact, those 5DMA lines on both IG and Yahoo Finance (I use the latter more) are updated intraday with new prices. They are not static numbers and get updated with new intraday stock prices. The old text-book definition of 5DMA clearly doesn't seem to apply in this case.

Do you or anybody know why this is?


Link to comment

@CowboyJJ, on a daily chart there is only one bar per day, the plot of the average of the previous 5 days will not move though the daily bar itself may lengthen or shorten.

The data plot itself is a single point for each day that has been joined up to the previous plot.

The term DMA can only be applied to a daily chart, if you change time frames it is no longer a DMA, if you are looking at a 1 hour chart has become the the HMA which is completely different and will update every 1 hour.

Link to comment


This topic is now archived and is closed to further replies.

  • image.png

  • Posts

    • Atomic Wallet is experiencing issues with their staking and rewards, so I would like to transfer my ATOMs to another crypto wallet. I contacted Atomic Wallet Support and they recommended Cosmostation Wallet and gave me instructions on how to do this. I followed the links they sent me, which required me to fill in my seed phrase. My ATOMs transferred to Cosmostation Wallet but were immediately transferred out. I never made that transaction. I contacted Cosmostation Wallet Support and asked them what happened. They informed me that I must have been talking to a scammer posing as support from Atomic Wallet. I contacted Atomic Wallet and they said I wasn't talking to a scammer and those links are legit. I lost my funds because my PC must be infected. Atomic Wallet wouldn't outright scam me would they?  
    • With the recent surge in "Cat Coins," a wave of playfulness and intrigue is sweeping the crypto community. KHAI, a meme token built on the Solana blockchain, is at the forefront of this movement. Fueled by a bullish community sentiment, KHAI has experienced a staggering 15.27% price increase in the past 24 hours, pushing its market cap to a noteworthy 24.4 million dollars. This impressive growth comes on top of a remarkable 94.3% price jump over the past week, significantly outperforming both the global market and other Solana-based cryptocurrencies. Could KHAI be the next big memecoin to reach unprecedented heights? Its recent listing on the Bitget exchange, accompanied by a giveaway event, certainly adds fuel to the fire. However, the question remains: will this newfound attention propel KHAI to even greater heights, or will it succumb to the volatility often associated with memecoins? Only time will tell.
    • Bitcoin halving is set for this week. Bitcoin Halving Event The cryptocurrency was hit hard over the weekend after Iran carried out a series of strikes against Israeli territory. The attack, in response to Israel’s attack on Iran’s consulate in Syria at the start of the month, saw in excess of 350 drones and missiles launched by Iran. According to the Israel Defence Force (IDF), ‘99%’ of these ‘threats’ were successfully intercepted. With the cryptocurrency sector being the only market open over the weekend, traders used the sector’s liquidity to hedge risk. Bitcoin hit a low of $60.6k as news of the impending strike filtered through, while Ethereum hit a multi-week low of $2,845. In the altcoin space, losses of 25% or more were seen, sparking multiple liquidation stories. Prices across the board are pushing higher today, but the weekend’s losses will take some time to fully recover. The weekend sell-off saw Bitcoin fall below both the 20- and 50-day simple moving averages for the first time since late January. Both of these will need to be recovered convincingly, along with a prior resistance-turned-support level at $69k, before Bitcoin can make a fresh attempt at the mid-March $73.78k all-time high. BITCOIN DAILY PRICE CHART – APRIL 15TH, 2024     Ethereum is over 3% higher today after making a multi-month low of $2,845 on Saturday. Ethereum must reclaim both the 20- and 50-day moving averages before $ 3,582 comes back into play. Above here, the April 8th/9th double high at $3,728 comes into focus. ETHEREUM DAILY PRICE CHART – APRIL 15TH, 2024   All charts via TradingView What is your view on Bitcoin and Ethereum – bullish or bearish?       Apr 15, 2024 1:30 PM +02:00 Nick Cawley, Senior Strategist DailyFX
  • Create New...