[labels,resids] = ardeglch(data,inlabels,modelorder,iqrcrit)
data
| Column vector of RR intervals or other data |
inlabels
|
Column vector of numerical labels. 0 indicates the corresponding point in
data is already known to be INVALID.
The invalid points are excluded when
fitting a model to the data. If you have no labels, just use
ones(size(data)), and all points will be used in fitting
the model.
|
modelorder
| The order of the auto-regressive model to fit to the data to detect outliers. (Default value: 3) |
iqrcrit
| Criterion for marking a point as a glitch, specified in terms of the number of multiples of the interquartile range that a point is distant from the nearest quartile. (Default value: 3.5) Higher values makes the program more selective about calling a point an outlier. |
labels
|
A revised set of labels, which marks as invalid (0) those points
found to be outliers. Points marked as invalid in inlabels
will still be marked invalid here.
|
resids
|
The residuals from the model fit to the data. These can be useful
for selecting iqrcrit or modelorder appropriately.
|
ardeglch attempts to find glitchy points in a data set, and
is particularly useful when there are no reliable labels attached to the
data. It fits an autoregressive model to the data, excluding from the fit
data points already marked as invalid. The residuals from this model
are examined for outliers; outlying points are labelled as glitchy.
Both forward predictive and backward predictive models are used, with the smaller of the two residuals being used for the purposes of detecting outliers. The method is particularly effective in indentifying sudden changes (as might be caused, e.g., by a PVC).
Non-glitchy points quite close to a genuine glitch
(with modelorder) are likely to be marked as glitches.
Note that the criteria for identifying glitches is based on
statistical outliers, rather than on a physiologically meaningful criterion.
Thus, in data with a large proportion of physiological glitches --- that is,
when the glitches are "normal" --- this program will tend not to find
the glitches, since they are not outliers.
When the characteristics of the data change dramatically within
the data set, it is best to divide the data into shorter segments
and deglitch each segment separately. This can be done with
ardglong.
I do not know who first suggested this method for identifying glitches. I believe that I first heard the idea from George Moody at MIT. -DTK
ardglong.