This macro calculates a median smoother with a default span of 3. The 1st observation of the smoothed data is the median of the 1st 3 data points (X1, X2, X3). The 2nd observation of the smoothed data is the median of the (X2, X3, X4). The 3rd observation is the median of (X3, X4, X5)… Thus, the smoothed data shows a moving median of the original data.
Be sure that Minitab knows where to find your downloaded macro. Choose . Under Macro location browse to the location where you save macro files.
If you use an older web browser, when you click the Download button, the file may open in Quicktime, which shares the .mac file extension with Minitab macros. To save the macro, right-click the Download button and choose Save target as.
With the span = 3, the next to the last smoothed value is the median of the last 2 data values. The last smoothed value is equal to the last data value.
Suppose you have data to be smoothed in C2, C3, and C4 and you want to store the smoothed data in C5, C6, and C7.To run the macro, choose and type:
%MEDSMOOTH C2 - C4;
STORE C5 - C7.
Click Run.