The Best Moving Average Settings and Trading Method

Moving averages are one most commonly used technical indicators. A moving average is simply a way to smooth out price fluctuations to help you distinguish between typical market “noise” and actual trend reversals. This article will learn you what is Simple Moving Average (SMA), Exponential Moving Average (EMA), Weighted Moving Average (WMA) and more importantly the best moving average settings.

What is Moving Average

As the name implies, moving average (MA) lines for a given period don’t plot the price at a given moment. Instead, each point on these lines is the average closing price for a certain number of prior completed candlesticks or periods.

For example, at any given point in time, a 200-period MA plots the average price over the past 200 periods. On a one-minute chart, in which each candlestick shows price movement over one minute, the 200-period MA is comprised of a series of average closing prices for the past 200 one-minute candles. On a daily chart, the 200-period moving average shows a series of average closing prices over the past 200 days.

As each new closing price is added, the oldest one is dropped from the calculation, hence the term moving average, or MA. In other words, what makes these MAs is that for each new candlestick, the calculation replaces the oldest closing price with the latest one. For example, over a 251-candlestick period, the 200-period MA calculation would drop the closing price from the 250th candle and replace it with the one from the most recent, the 251st period. These 200 most recent closing prices would be totaled and divided by 200 to give the latest price level of the 200-period MA. This is the formula for the most basic MA, the Simple Moving Average (SMA).

Continue reading for more information or start playing around in a ​risk-free demo account and test the best moving average settings in real-time.


Understanding of Moving Average Indicator

Moving Average indicators has two advantages over the other types of trend lines previously discussed:

1. They clarify trend direction: As a series of average prices over a given period rather than real-time prices, MAs filter out random price movements and present a smoother, clearer picture of the trend for the period they cover versus the series of candlesticks. Because MAs are dynamic and changing trend lines, MAs can provide a useful look at the more subtle price fluctuations within the overall trend that hand-drawn straight trend lines or channels will miss.

2. They are often more reliable support/resistance (s/r) because everyone’s MAs look the same: They’re built from an objective mathematical formula, so unlike trend and channel lines, a given type (Simple Moving Average - SMA, Exponential Moving Average - EMA, Weighted Moving Average - WMA) and duration of MA for a given time frame looks the same on everyone’s chart and presents the same picture of trend and support/resistance for all viewing it. That’s a valuable attribute. By watching the most widely followed MAs some of the best forex indicators, you have a better understanding of moving average and what the rest of the herd believes to be the s/r of these trend lines. That allows you to anticipate and exploit their moves.

Simple Moving Average Formula

The simple moving average (SMA) calculates an average of the last n prices, where n represents the number of periods for which you want the average:

Simple moving average formula = (P1 + P2 + P3 + P4 + ... + Pn) / n

For example, a four-period SMA with prices of 1.2640, 1.2641, 1.2642, and 1.2641 gives a moving average of 1.2641 using the calculation [(1.2640 + 1.2641 + 1.2642 + 1.2641) / 4 = 1.2641].

While knowing how to calculate a simple average is a good skill to have, trading and chart platforms calculate this for you. Simply select the SMA indicator from the list of charting indicators, apply it to the chart, and adjust the number of periods you want to use.

You typically make adjustments to the indicators in the Settings menu section of the trading platform. On many platforms, you can locate the settings by double-clicking on the indicator itself.

Exponential Moving Average Formula

The exponential moving average (EMA) is a weighted average of the last n prices, where the weighting decreases exponentially with each previous price/period. In other words, the formula gives recent prices more weight than past prices.

Exponential moving average formula = [Close - previous EMA] * (2 / n+1) + previous EMA

For example. a four-period EMA with prices of 1.5554, 1.5555, 1.5558, and 1.5560, with the last value being the most recent, gives a current EMA value of 1.5558 using the calculation [(1.5560 - 1.5558) x (2/5) + 1.5558 = 1.55588].

As with the SMA, charting platforms do all the EMA calculations for you. Select the EMA from the indicator list on a charting platform and apply it to your chart. Go into the settings and adjust how many periods the indicator should calculate, for example, 15, 50 or 100 periods.

Weighted Moving Average Formula

The weighted moving average (WMA) gives you a weighted average of the last n prices, where the weighting decreases with each previous price. This works similarly to the EMA, but you calculate the WMA differently.

Weighted moving average formula = (Price * weighting factor) + (Price previous period * weighting factor-1)...

WMAs can have different weights assigned based on the number of periods used in the calculation. If you want a weighted moving average of four different prices, then the most recent weighting could be 4/10, the period before could have a weight of 3/10, the period prior to that could have a weighting of 2/10, and so on.

Disadvantages of Simple Moving Averages and Their Alternatives 

The main disadvantage of using single Simple Moving Average lines is that by their nature of being a series of average prior prices, they lag the current price. Using multiple MA lines together can turn MAs from lagging indicators into leading indicators. To partially remedy this time lag for individual Simple Moving Averages (SMAs), Exponential Moving Averages (EMAs) and Weighted Moving Averages (WMAs) are available. Leaving aside the mathematical distinctions, know that though SMAs weigh the oldest and newest prices equally, WMAs and EMAs assign greater weight to the most recent data and are a bit more responsive to recent price changes. No clear consensus exists on which is better or more popular. Whether one or another works better for you will be a matter of experiment (see how a Forex EA Builder can generate the best moving average settings in a few clicks). The more responsive WMA and EMA are more accurate if recent prices are more indicative of where the trend is going. Sometimes that is true, and sometimes it’s not.

The Most Important Moving Averages to Watch 

The 5-, 10-, 20-, 50-, 100-, and 200-period MAs are widely followed in most markets and time frames. They are the standard sampling of shorter and longer-duration MAs and provide a degree of self-fulfilling prophecy. They indicate s/r because traders believe they are s/r points. 

The longer-duration MAs are particularly popular support/resistance indicators. For example, even the mainstream financial press aimed at laymen will usually mention if a major stock index crosses its 50- or 200- day MA. The forex media (which exists almost exclusively on the Internet) will quickly note if a major pair hits or crosses one of the longer-duration MAs like its 50-, 100-, or 200-day MA. Similarly, because MAs in longer time-frames are older, 20-, 50-, or 200-day, week, and month MAs get more attention because they provide much more significant s/r than those durations in shorter time frames.

By all means, tinker with slight variations on these. For example, some prefer to shorten their sampling period to get a head start on the crowd (at the risk of getting a premature, false signal). Slightly longer or shorter sampling periods have their advantages and disadvantages. The following is a summary.

The Best Moving Average Settings 

To understand and use MAs, you need to understand the relative strengths and weaknesses of the longer- and shorter-duration MAs, and the older ones you’ll see on daily to monthly charts versus the younger MAs in the shorter time frames. Here’s what you need to know.

Shorter Durations (5, 10, 20 Periods): More Responsive to Price Changes, Weaker, Less Significant Support/Resistance

The advantages:

  • More responsive to price changes and are quicker to indicate a change in trend.
  • Are better at showing short-term trends.
  • May provide warning of trend changes when they cross longer duration MAs.

The disadvantages:

  • Weaker, less significant s/r, so they don’t provide as reliable signals of trend continuation or reversal as the longer-duration MAs when they are breached or when they hold.
  • Shorter-duration MAs don’t display the overall trend as well as longer duration MAs when prices are bouncing around because the shorter duration MAs follow each price move so closely.

Longer Duration (50, 100, 200 Periods): Less Responsive to Price Changes, Stronger, More Significant S/R

The advantages:

  • Stronger, more significant s/r provide more reliable signals of trend continuation or reversal when they are breached or when they hold.
  • They are better than the shorter-duration MAs at displaying the overall trend when prices are volatile because a more sustained trend is needed to move these MAs.

The disadvantages:

  • The longer the duration, the further they lag current price action.

The Same Advantages and Disadvantages Apply When Comparing Younger versus Older MAs.

The same durations on longer time frame charts are older than those on shorter time frame charts. Thus a 200-day MA is a much more significant s/r than a 200-hour MA but is less responsive to price and trend changes.

Examples of Moving Averages Behavior

Let’s look at some examples of how long- and short-term MAs behave. In Figures below, the shorter MAs, the more closely they follow price. The longer the MAs, the smoother they are and the less often they tend to be breached.

This is a EURUSD weekly chart, meaning each candlestick shows a week’s price movement for the Euro-USD currency pair. Thus, the 10-period EMA line is a 10-week EMA, the 50-period EMA is a 50-week EMA, and the 200-period EMA is a 200-week EMA, which is a good example of setting accurate moving average indicators.

Notice how:

  • Shorter-term MAs show price changes faster than longer-term MAs: The shortest duration 10-period MA follows price more closely than the others, whereas the longer-duration 50- and 200-period MAs are progressively more smoothed, with the 200-period MA almost flat, reflecting how minimal the net price was over the period shown despite the volatility. That’s a potentially important point that you might have missed by looking at only the candles. 
  • Longer-term MAs provide better s/r: The shorter-duration 10-week MA is breached seven times, far more often than the 50-week (two times) or 200-week. 
  • Shorter-duration MAs are less reliable s/r than longer ones.

Again, note the tradeoffs:

  • See how the shorter-duration MAs are more responsive, and how the longer-term MAs are better at showing the overall trend because they don’t jump with every short-term move.
  • The longer-term MAs are breached much less frequently. Indeed, if the 200-day EMA is breached, we will have to consider whether this longer-term downtrend is reversing.

Because this is a daily chart, these are 200-, 100-, 50-, 20-, and 10-day EMAs.

Additional Points about the Moving Average Settings

The Best Moving Average Settings: Trading has nothing to do with discerning what logically should happen. Instead, it’s all about anticipating what the crowd will do and doing it first in your chosen time frame before they bid up to your entry price or bid down your selling price.

  • Don’t Think: What logically should happen?
  • Think: What will the crowd think the other investors will do?

This kind of thinking is important for short-term trades meant to be concluded within a few days at most, or intraday trades and trades based.

Moving Averages Method

Though you should watch the most popular MAs, traders can and do experiment with less or more radical variations on these. Some will use slightly shorter-duration MAs when seeking more responsive trend lines in order to catch trend changes before the rest of the crowd, but at a cost of catching more false signals. Others will opt for slightly longer durations in order to filter out all but the most proven trends. That may reduce the number of losing trades at a cost of missing some moves or accepting reduced profits on winning trades due to later entries and exits. The best moving average settings for you will depend greatly on your risk tolerance, skill level, ability to monitor trades in real-time, and thus your chosen time frame and trading style

When we cover the moving averages method, we’ll see that this kind of tinkering can be useful for developing entry and exit signals.

Before you start tinkering with profitable moving average methods, get comfortable with those covered in this article. Only then will you have the background needed to start customizing your moving average method.

There are two common types of moving average technique - crossovers used in the moving average method to signal possible trend reversals.

1. Price itself crosses over or under a moving average.
2. Shorter-duration moving averages cross over or under longer, slower-moving averages.

Each type signals changing the momentum that could be the start of a new trend.

Price Crosses Over or Under a Moving Average

The first moving average method and type of MA crossover is when the price moves through an important moving average. For example, see Figure below. When price moves below its 50-period simple moving average, or SMA (candle A), it’s a sign the trend may be moving lower. When price moves above its 50-period SMA, (candles B and C) it’s a sign that the trend may be reversing higher. Traders who exited long positions on July 1 (A) when price closed below the 50-day SMA avoided a month of losses (and the risk that the pullback could have turned into something far worse). If they entered new long positions when price closed above the 50-day SMA on August 6 (B) or August 11 (C), they caught the beginning of the next move higher.

This chart has two sets of Bollinger Bands, one and two standard deviations from the 20-day SMA baseline in the middle. Here we’ve added a 50-day SMA, which price crosses at points A and B. Thus we can use a combination of both Bollinger Bands and moving average crossovers of the 20- and 50-day SMAs.

Note also that there was another sign on August 6 (B) that the trend had resumed. Gold closed the day in its upper Bollinger Band buy zone, providing additional confirmation that the uptrend had resumed. As noted earlier, moving average crossovers and Double Bollinger Bands (DBBs) - the most accurate forex indicator - make a potent combination for timing entries and exits. The moving average crossovers provide an earlier advanced warning of a trend change, and the DBBs confirm it. More conservative traders or investors might choose not to enter positions until price enters the DBB buy or sell zone. More aggressive ones will enter at least partial positions when they get the moving average crossover. Regardless of your risk tolerance, the fundamental context should be considered before deciding to take a more conservative or aggressive approach.

Two points to remember with this moving average method:

1. Adjust your risk appetite to market conditions. If your analysis makes you confident in the trend, you should be more inclined to open partial positions based on whatever moving average crossover tends to signal the start of a trend. If the evidence is equivocal, you might want to wait until price enters the DBB buy or sell zone, or have some other further confirmation of the move.
2. Which moving average should price cross over to give you a signal for a new trend? While we used the 50-period SMA in the example, that will depend on which one(s) you find provide(s) the best results: that is, those MAs that provide signals early enough to catch most of the move, but not so early that you get more false signals than you’re willing to accept.

Moving Averages Cross Each Other

The other type of trend reversal indicator using moving average crossovers is when:

  • A shorter-duration moving average crosses over a slower, longer duration moving average, signaling upward, bullish momentum.
  • A shorter-duration moving average crosses under a slower, longer-duration moving average, signaling downward, bearish momentum.

That is, instead of price crossing over or under a moving average, two separate moving averages cross.

Examples of Moving Average Method

As mentioned earlier, your goal is to develop a moving average method, which in its simplest form is just some rules for when you enter and exit trades for a given currency pair or other assets. It doesn’t have to be complex. Typically even a simple system that you’ve found works most of the time with a given asset is better than no system at all. To clarify, let’s look at a few cases of a very simple moving average method using MA crossovers.

For example, if the 20-day MA crosses above the less responsive 50-day MA, it’s a sign that the trend is more likely to be moving higher. Similarly, if the 20-day MA crosses under the 50-day MA, it’s a sign that the trend is more likely to be moving lower.

The movements of the shorter-term moving averages are the trigger because, as noted earlier, shorter-duration moving averages like the 20-period.

MA is more responsive to recent changes than longer-duration ones like the 50-period MA. Thus when a shorter MA crosses above or below a longer one, it’s an alert that a longer-term change may be coming, even when this trend is not so clear from the candlesticks themselves.

For example, look again at the daily gold chart we saw in Figure above, reproduced in Figure below. Note that while I use a 20-day SMA here, I also use a 50-day exponential moving average (EMA) (more responsive than SMAs) in order to make their interaction a bit more sensitive to recent price action. You can do this kind of mix and match of EMAs and SMAs as experience warrants.

Note how the 20-day SMA (used as part of the DBBs) crossed over the 50-day EMA on March 2, 2010 (A1). Even though gold continued to fall for a few more sessions, the MA crossover signaled that the overall trend over the past 20 periods (days on a daily chart) was rising, and in fact, this crossover would have alerted you that gold might soon break higher, which it did.

If you did nothing else but stay long in gold until the 20-day SMA crossed below the 50-day EMA on July 19, 2010 (A4), you’d have caught a long uptrend and gotten out before some of the downtrends that followed.

Of course, we don’t rely on just one moving average indicator. Depending on other moving average indicators you may have used, you might well have had better results. For example, having studied gold’s past performance, you may have added some rules that might have improved your performance over the February 26 to August 12 period. For example, you might have only added the application of Double Bollinger Bands along with the MA crossover to form the following overly simple moving average method:

  • The 20-day SMA is above the 50-day EMA.
  • Once that happens, apply the four rules of Double Bollinger Bands (DBBs). That is, once the 20-day SMA has crossed the 50-day EMA and you are looking to buy gold:
  • Buy when gold has a daily close within or above its DBB buy zone.
  • Sell if gold has a daily close below its DBB buy zone.

Note how well combining just these two rules would have worked. Look again at Figure above, and at the continuation in Figure below.

A few choppy weeks after your initial entry on March 2 (A1), on March 31 (just before the candle labeled A2) gold crossed and closed above both its 50-day and 20-day MAs, then the next day on April 1 (A2) gold crossed into the DBB buy zone. By just using this simple rule of entering and staying long while gold was in its DBB buy zone, and exiting when it closed below that zone, you would have caught most of the uptrend in gold price over the following eight months, avoided almost all of the drop on July 1 (A3) and the choppy sideways movement from July to early August, and caught virtually all of the uptrend from mid-August onward when the 20-day SMA crossed back over the 50-day EMA on August 22 (D1). You’d have missed the first weeks of gold being back in the DBB buy zone that began in early August (B and C), but that’s the price you pay to avoid the choppy market.

Note what happened from mid-August to mid-October (D1 to D2).

Setting up Moving Average in MetaTrader 4/5

This section shows you how to set up Moving Average in MetaTrader 4/5. It assumes that you have opened a chart.

Add the Moving Average and set the parameters of this indicator

  1. Click Insert and move your mouse over Indicators and Trend
  2. Click Moving Average

moving average

Setting the common parameters

After you have completed the step above, the settings menu appears.

moving average

Most indicators can be controlled by several common parameters.

There are two types of parameters:

  • Calculations of the indicator: e.g. the number of periods used for the Moving Average (you do not need to worry too much about this in the beginning)
  • Visuals of an indicator: e.g. how it will look, the color and thickness of the lines, etc.

moving average

Changing parameters at a later time

To change the settings of the indicator directly on the chart at a later date:

  1. Right-click the Moving Average (you will have to be exact on the line of the indicator to get the menu seen below)
  2. Choose MA(14) Properties – The (14) is the respective parameter (Periods) and can differ, depending on your choice when setting the parameters.

The parameter menu appears again where you can change the indicator.

moving average

Deleting an indicator

To delete the Moving Average:

  1. Right-click the indicator that you want to delete (you will have to be exact on the line of the indicator to get the menu shown below).
  2. Click Delete Indicator.

moving average

The Moving Average will disappear from your chart.

Understanding some of the best moving average techniques is important, but if you want some help, MetaTrader 5 AM Broker offers a useful Moving Average toolkit and our trainers can provide you the right guidance. Play around in a ​demo account and notice how this Moving Average method can make you serious money today. Alternative, use an Expert Advisor Builder to generate automated Moving Average Methods backtested and optimized.

>> Let's Get You Started

What's Next







Categories:  Forex