remove_average function takes a multi-channel signal and removes the
average value over a filtering window.
remove_average(df, sr, order = 0.5)
dataframe. The input multi-channel signal. The first column is timestamps in POSXlct format. The rest columns are signal values.
number. Sampling rate in Hz of the input signal.
number. Window size (in seconds) of the filter. Default is 500 ms.
dataframe. Filtered signal.
This function filters the input multi-channel signal by removing the average value within each sliding window. The sliding window size is decided by \(w = sr * order\).
This function has been considered as one of filtering options during the development of MIMS-unit algorithm. But the released version of MIMS-unit algorithm does not use this function for filtering.
# Use sample data df = sample_raw_accel_data # View input illustrate_signal(df, plot_maxed_out_line = FALSE)# Apply filtering output = remove_average(df, sr=80, order=0.5) # View output illustrate_signal(output, plot_maxed_out_line = FALSE)