impute_speeds {trackeR} | R Documentation |
Impute speeds
Description
Impute speeds of 0 during small breaks within a session.
Usage
impute_speeds(
session_data,
from_distances = TRUE,
lgap = 30,
lskip = 5,
m = 11,
sport = "cycling",
units = NULL
)
imputeSpeeds(
session_data,
from_distances = TRUE,
lgap = 30,
lskip = 5,
m = 11,
sport = "cycling",
units = NULL
)
Arguments
session_data |
A multivariate |
from_distances |
Logical. Should the speeds be calculated from the distance recordings instead of taken from the speed recordings directly? |
lgap |
Time in seconds corresponding to the minimal sampling rate. |
lskip |
Time in seconds between the last observation before a small break and the first imputed speed or the last imputed speed and the first observation after a small break. |
m |
Number of imputed observations in each small break. |
sport |
What sport does |
units |
Units of measurement. |
Value
A multivariate zoo
object with imputed observations:
0 for speed, last known position for latitude, longitude and altitude,
NA for all other variables. Distances are calculated based on speeds after imputation.
References
Kosmidis, I., and Passfield, L. (2015). Linking the Performance of Endurance Runners to Training and Physiological Effects via Multi-Resolution Elastic Net. ArXiv e-print arXiv:1506.01388.
Frick, H., Kosmidis, I. (2017). trackeR: Infrastructure for Running and Cycling Data from GPS-Enabled Tracking Devices in R. Journal of Statistical Software, 82(7), 1–29. doi:10.18637/jss.v082.i07