AethSmoothing smooths aethalometer data based on Pikridas et al., 2019, which in turn was based on Hagler, G.: Post-processing Method to Reduce Noise while Preserving High Time Resolution in Aethalometer Real-time Black Carbon Data, Aerosol Air Qual Res, doi:10.4209/aaqr.2011.05.0055, 2011.
The algorithm uses uncorrected data (no Weigartner or any other correction) as delivered by the instrument or calculated by the user. Only homogeneous time series are considered.The original code by Hagler et al. can be found in the supplementary info of the paper cited above. It is written in matlab as well.
[response_smoothed,response_std,positions, NumberOfPoints ] = AethSmoothingUpload(Time,Reponse,Attenuation);
Time, Mx1 vector. Time of the data in julian format, ie 1 = one day
Response, Mx1 matrix The response to be smoothed, it can be babs or BC mass in any units
Attenuation, same size as Response. The attenuation as provided by the instrument or calculated by the user (Important read note below).
This input must have enough accuracy for the function to operate properly. 4 decimal accuracy is optimal. 3 decimal accuracy will suffice in most cases.
'method', the method to use for smoothing. Possible options are:
{'moving'}
'lowess'
'sgolay'
'average'
The moving method is better tested. The lowess method is very problematic. The average method will smooth similar to the original ONA algorithm based on the reference above (ie by Hagler et al., 2011).
'ATNincrement', A number below unity.
Arranges the intensity of the smoothing. The
greater the value the more intense the smoothing. A default value
of 0.05 is used if the increment is not set.
'Weights', {0} or 1.
This parameter is only valid if the moving method is used. In case the sample has large variations in the concentration of BC the method may yield unrealistic results. Applying weights eliminates such problems. However, applying weights may increase the effect of outliers. So it is advised for both the normal and weighed method to be used in parallel. Applying weights will
distort the edges (beginning and end) of your time series.
response_smoothed, The response smoothed based on ATNincrement
response_std, one standard deviation of the smoothed response positions, the positions of the data smoothed.
This output helps duplicate the result. However, when you use weights you cannot duplicate the result
NumberOfPoints, how many data points were used for each average
[smooth_moving,smooth_moving_std,smooth_moving_pos,smooth_moving_np ] = AethSmoothing(Time,babs,Attennuation);
[smooth_moving,smooth_moving_std,smooth_moving_pos,smooth_moving_np ]...
= AethSmoothing(Time,babs,Att,'method','moving','ATNincrement',0.05,'Weights',0);
[smooth_moving,smooth_moving_std,smooth_moving_pos,smooth_moving_np ] = AethSmoothing(Time,babs,Attennuation, 'Weights',1);
[smooth_moving,smooth_moving_std,smooth_moving_pos,smooth_moving_np ] = AethSmoothing(Time,babs,Attennuation, 'ATNincrement',0.01);
Michael Pikridas (2019). AethSmoothing (https://www.mathworks.com/matlabcentral/fileexchange/71108-aethsmoothing), MATLAB Central File Exchange. Retrieved April 3, 2019.