Basics of Biomechanics #4: Conditioning Signals

Welcome back to Basics of Biomechanics, a series of blog posts covering foundational topics in the field using practical, data-driven examples. In biomechanical analysis, before we can extract useful outcomes from our measurements we often need to “clean them up” in order to improve their quality or usefulness. As we will see, in many cases, signal conditioning (and small details about the way this is done) can make a significant difference to the interpretation of our results.

One of the main reasons for signal conditioning is that measurements are almost always at least slightly “dirty” i.e. they contain some noise or content that is undesirable. In some cases there may be some offset error or slowly changing (drift) error in the signal that needs to be removed. However, most forms of noise occur in the high frequency range i.e. they are very “fast” parts of the signal. In this case, we need to perform what is called signal smoothing or filtering. This will be illustrated using our ongoing example of countermovement jump analysis.

EMG analysis using sliding window smoothing

Let us consider that – alongside our force plate data – we were able to simultaneously collect calf muscle excitation using a wireless surface electromyography (EMG) system and a bipolar electrode on the gastrocnemius. The graph below shows a sample of left calf EMG signal and the vertical ground reaction force signal measured during one countermovement jump. In comparison to the unipolar and relatively smooth force signal, the EMG signal is bipolar and contains much more high-frequency content. The typical approach in EMG analysis is to rectify and smooth this raw signal into a slower-changing unipolar signal that reflects the general onset and offset of muscle excitation.

One popular group of methods for smoothing signals is the sliding window technique. In this approach, the smoothing algorithm considers a fixed number of adjacent data points in a signal (the window). The algorithm slides the window forward in time through the signal from beginning to end (one sample at a time) and performs a certain calculation on the points in the window. A common implementation of a sliding window is the moving average, which creates a smoothed signal of the same length as the input signal using the mean value for each window. Typically, the mean value is stored for the data point in the middle of the window to avoid time-shifts (e.g. peaks shifting left or right on the timeline). The key characteristics of any sliding window algorithm are the window length (usually represented by time rather than number of samples) and the window statistic (mean, median, mean absolute, root-mean-square etc.).

Challenge #1: how would the choice of smoothing algorithm in the graph above affect an analysis of how much muscle excitation there was and when it occurred? How would you go about choosing the window size and statistic?

For our EMG analysis, mean absolute and RMS statistics work well because they inherently rectify the signal before smoothing. Typical sliding window sizes for EMG analysis are in the region of 50-200ms, depending on the application. The graph below illustrates that while different sliding window algorithms produce similar results, the choice of interval and statistic can affect interpretation. The RMS statistic tends to produce larger amplitudes than the mean absolute statistic because it is more affected by spikes in the signal (note that the magenta line is higher than red line). Similarly, larger window sizes tend to produce lower peak amplitudes but wider excitation regions (the green line is flatter and wider).

Butterworth filters

Another popular group of methods for smoothing signals in biomechanics (especially in motion capture) is Butterworth filtering. A Butterworth filter attempts to decompose a signal into separate frequencies, allowing it to eliminate certain frequency ranges from the signal. Depending on the range of frequencies that need to be eradicated, a filter can either be classified as a low-pass, high-pass, band-pass or notch filter. The most common is a low-pass filter, which removes frequencies in the signal above a certain threshold (the cut-off frequency) i.e. it lets low frequencies pass through. Lastly, the order of the Butterworth filter is a positive integer reflecting the complexity of the filter – typically a 4th-order filter is used in biomechanics.

In our jump analysis, we may decide to evaluate the rate of force development (RFD). The instantaneous RFD is a signal representing the time-derivative of the vertical force signal. As shown in the first axis of the graph below, the RFD signal contains some high frequency content that may be undesirable. If we are unsure about the desirable frequency content of the RFD signal, we can instead apply filtering of the vertical force signal if we have better information about what frequencies should be contained in that signal. The second axis of the graph below illustrates the effect of different cut-off frequencies used to condition the vertical force with a 4th-order low-pass Butterworth filter.

Challenge #2: the high frequency ripple in the unfiltered RFD signal is completely removed by the Butterworth filters. Is this ripple definitely noise in the force measurement, or could it be physiological instability in muscle forces? How would you go about deciding whether to filter it out or not?

It is quite clear in the graph above that the lower the cut-off frequency, the greater the difference between the unfiltered and filtered RFD signals i.e. the greater the smoothing effect. Similarly to the sliding window example, low-pass filtering flattens and broadens peaks and troughs in the signal. In this case, since we filtered the force data (and not the RFD) it is important to inspect the effect of the filter on that signal as well. In the graph below we can see that the 20Hz filter heavily distorts the shape of the vertical force curve. Although the other two filters preserve the overall signal shape much more, the 50Hz filter creates a ripple near takeoff which the 100Hz filter does not.

The numerical value of the cut-off frequency is a crucial decision and should be carefully considered. It is also important that a Butterworth filter is run twice – forwards and backwards in time. This is often called zero-phase, zero-lag or bidirectional filtering prevents the filtering from causing time shifts in the signal. It also often makes sense to filter measured signals than calculated signals (force instead of RFD for example), since we may have more information about the noise sources present in our measurements than in our calculations.


Signal conditioning can involve many different types of algorithms, but the staple in biomechanics is low-pass filtering and sliding window smoothing. As shown in the examples above, it is important to understand the settings for the algorithms you (or your equipment software) will apply to your data. If you do not condition your signals enough, too much noise may remain and affect your results. However, over-smoothing of signals can also significantly alter your outcomes and lead to errors in interpretation. While there may not always be an easy and clear cut answer to what your optimal signal conditioning may be, it is important to search the literature to determine the best practices for your particular technology and biomechanics application.

Leave a Reply

%d bloggers like this: