I am trying to rewrite code from Matlab in R and I am failing at the Hampel-Filter which seems to be distinct.
absmeasuredAccelerations<-(9.817899,9.923724