Differences between successive angles in a series
Source:R/circular.R
circ_successive_difference.RdApplies circ_difference() along a vector, comparing each angle with the one
lag positions before it — the turn from one heading to the next, rather
than the difference between two angles you name. Unlike base::diff() the
result is the same length as x, padded with NA at the start, so it can be
used inside dplyr::mutate().
Value
A numeric vector the same length as x, in radians. The first lag
entries are NA; the rest are angular differences in (-pi, pi].
See also
Other circular statistics:
circ_difference(),
circ_mad(),
circ_mean(),
circ_median(),
circ_sd()