Moving Average Parameters

Three Moving Average Parameters

So you want to add a moving average on your charts. What are the parameters you have to set or choose? There are only a few (three):

Let’s now explore each of the parameters.

Parameter 1: Price Used for Moving Average Calculation

Most typically people use every bar’s closing price to calculate moving averages. In many cases this is justified by the special role the closing price has. For example, every day’s closing price of a stock index represents the stock market’s consensus at the end of that trading day, when traders are closing their intraday positions and preparing their portfolios for the night when they will not be looking at the market.

On the other hand, closing prices of bars are much less significant on intraday charts – the information regarding at which price the market was trading exactly at the end of a particular 5 or 10 minute period during the day has little meaning for most market participants. Therefore you can look at alternative methods of calculating moving averages when you are working with intraday data: moving averages can be calculated from the averages of high and low of each bar, or from the so-called typical price (the average of high, low, and close), or from the average of all four prices (open, high, low, and close).

See more details in Calculating Moving Average from Close and the Other Methods.

Parameter 2: Moving Average Period Length

The length of the moving average or more precisely the number of bars included in the moving average calculation is probably the most discussed of the three parameters. You can calculate moving average from just a few (e.g. 8) most recent price bars and you will see that it reacts very quickly to every little change in the market’s direction. Alternatively, you can include tens or hundreds of price bars in the calculation (e.g. 200 bars is a popular setup). This way you will filter out all the bar-to-bar noise – the long period moving average will reflect only the meaningful, long-term price trends.

Besides looking at the number of bars, you naturally also have to take into consideration how long each bar is. While 10 bars represent 2 weeks on a daily chart, they are less than one hour on a 5 minute chart.

There is no ideal moving average period length, as different trading styles and strategies require looking at different information. The problem of finding a good moving average period was discussed here: Moving Average Period.

Parameter 3: Moving Average Type

The most common moving average type is simple moving average. As its name suggests, it is also the simplest one to calculate and understand (that’s probably the main reason why it’s the most popular). Simple moving average is (simply) the arithmetic average of the last N bars (N is the moving average period discussed above). You sum up N most recent prices and divide the result by N.

Besides simple moving average, there are other types. There are only little variations in the formulas and sometimes it is difficult to tell which type of moving average it is just by looking at a chart. For example, exponential moving average puts more weight to the most recent prices and therefore it appears to be reacting a bit faster to price changes compared to the simple moving average. Other frequently used moving average types include least-square moving average, adaptive moving average, or weighted moving average. If you are creative and good with numbers, you can even design your own proprietary methods (nevertheless, the usefulness of such effort is questionable, given the little differences and little extra information you get).

Which Moving Average Parameters to Use?

If you have not done much quantitative testing and have no idea which moving average calculation method may be effective for your trading approach, I would suggest you start with the very basic. Take simple moving average calculated from closing prices (this is the setup your charting software most likely has as default) and focus your energy on finding a good moving average period length. Also keep in mind that moving average is just one tool, just one piece of the analysis, and you will probably need to include other things (like the fundamentals, volume, or price action) into your decision making to build a sound trading strategy.

Related pages

basic black scholescoefficient of kurtosiswilder rsimacd histogram strategysample variance excel formuladefining formula standard deviationcolor note padstandard deviation equation in excelpopulation covariance formulacalculating sharpe ratiostatistics kurtosiscalculating standard deviation excelblack scholes calculationprice weighted index calculationweighted average inventory costingcalculate dividend yieldstock intrinsic value formulaoptions delta calculatormacd histogram formulatvix optionsvolatility calculation black scholeskurtosis calculatorstdev ifcost variance calculationskewness and kurtosis calculatorcalculate formula in excelstock calculation in excelimplied volatility excelblack & scholes modelcubed formulanotepad font sizewhat is the formula for variance in exceloptions straddle calculatorsum of squared deviations formulavix 3xblack scholes graphlist of 13f securitiesoptions profit and loss calculatorhow to use the normdist function in excelwacc debtcalculating standard deviation on excelnotepad colorvix futures contangodelta symbol in exceloption greek definitionsstandard deviation formula shortcutweighted average cost of capital calculatoryahoo finance historical exchange ratesyahoo historical pricenorm s distavco methodnegatives and positives calculatorvariance covariance var13f filings hedge fundsvix definitionlist of etnsblack scholes calculationeuro stoxx 50 wikiedgar 13fhow to delta hedgebull spread using callsexcel calculate standard deviationoption trading spreadsheetoptions calcformula for variance for grouped datahow to calculate annualized volatilitywacc market valuethe greeks financewhat happens when you square a negative numberblack scholes stock option calculatorvix index bloombergdefinition skewnesshow is the dow jones calculated