Skip to content

Quick-tip 20 | Linear regression of a moving average

A Gold Pass member requested a tutorial about how to do a linear regression calculation on a moving average. He wanted to plot the slope angle for all the bars on the chart. This quick-tip references tutorial 48.

Video explanation

Since the main reason for this program it to plot the angle of the slope, it would make sense to comment out the drawing statement, especially if a large number of bars are loaded.