\documentclass[nojss]{jss} \usepackage{amsmath,amssymb,amsfonts,thumbpdf} \usepackage{dsfont} %\usepackage{pstricks} \usepackage{tikz} \usepackage{setspace} \usepackage{subcaption} \usepackage{color} %% additional commands \newcommand{\squote}[1]{`{#1}'} \newcommand{\dquote}[1]{``{#1}''} \newcommand{\fct}[1]{{\texttt{#1()}}} \newcommand{\class}[1]{\dquote{\texttt{#1}}} %% for internal use \newcommand{\fixme}[1]{\emph{\marginpar{FIXME} (#1)}} \newcommand{\readme}[1]{\emph{\marginpar{README} (#1)}} \newcommand{\iknote}[1]{{\color{blue} \bf [IK: #1] \marginpar{NOTE}}} \newcommand{\hfnote}[1]{{\color{orange} \bf [HF: #1] \marginpar{NOTE}}} \author{Hannah Frick\\University College London \And Ioannis Kosmidis\\University of Warwick \\ The Alan Turing Institute} \Plainauthor{Hannah Frick, Ioannis Kosmidis} \title{\pkg{trackeR}: Infrastructure for Running, Cycling and Swimming Data from GPS-Enabled Tracking Devices in \proglang{R}} \Plaintitle{trackeR: Infrastructure for Running, Cycling and Swimming Data from GPS-Enabled Tracking Devices in R} \Shorttitle{\pkg{trackeR}: Infrastructure for Running, Cycling and Swimming Data in \proglang{R}} \Keywords{sports, tracking, work capacity, running, cycling, distribution profiles} \Plainkeywords{sports, tracking, work capacity, running, cycling, distribution profiles} \Abstract{ {\color{blue} This introduction to the \proglang{R} package \pkg{trackeR} is a modified version of \cite{trackeR:Frick+Kosmidis:2017}, published in the \emph{Journal of Statistical Software}. The majority of changes and additions in the text are due to work by Ioannis Kosmidis, which involved the complete rewrite of most of the \pkg{trackeR} codebase at version 1.1.0, in order to make the package faster across the board and include support of all running, cycling and swimming and sport-specific units and variables, fix bugs, and implement new features and enhancements.} The use of GPS-enabled tracking devices and heart rate monitors is becoming increasingly common in sports and fitness activities. The \pkg{trackeR} package aims to fill the gap between the routine collection of data from such devices and their analyses in \proglang{R}. The package provides methods to import tracking data into data structures which preserve units of measurement and are organised in sessions. The package implements core infrastructure for relevant summaries and visualisations, as well as support for handling units of measurement. There are also methods for relevant analytic tools such as time spent in zones, work capacity above critical power (known as $W'$), and distribution and concentration profiles. A case study illustrates how the latter can be used to summarise the information from training sessions and use it in more advanced statistical analyses.} \Address{ Hannah Frick\\ Department of Statistical Science\\ University College London\\ Gower Street\\ London, WC1E 6BT\\ United Kingdom\\ E-mail: \email{hannah.frick@gmail.com} \\ URL: \url{http://www.ucl.ac.uk/~ucakhfr/} \bigskip \\ % Ioannis Kosmidis \\ Department of Statistics \\ University of Warwick \\ Gibbet Hill Road \\ Coventry, CV4 7AL \\ United Kingdom \\ \smallskip E-mail: \email{ioannis.kosmidis@warwick.ac.uk} \\ URL: \url{http://www.ikosmidis.com} } %% Sweave/vignette information and metadata %% need no \usepackage{Sweave} \SweaveOpts{engine = R, eps = FALSE, keep.source = TRUE} %\VignetteIndexEntry{Infrastructure for Running, Cycling and Swimming Data} %\VignetteDepends{trackeR} %\VignetteKeywords{sports, tracking, W', running, cycling, swimming distribution profiles, R} %\VignettePackage{trackeR} <>= options(width = 70, prompt = "R> ", continue = "+ ", useFancyQuotes = FALSE) library("trackeR") library("ggplot2") data("runs", package = "trackeR") set.seed(403) cache <- FALSE @ \begin{document} \section{Introduction} \label{sec:intro} %% data collection: what/how and why Recent technological advances allow the collection of detailed data on fitness activities and on multiple aspects of training and competition in professional sport. The focus of this paper is on data collected by GPS-enabled tracking devices and heart rate monitors. Such devices are routinely used in fitness activities such as running, cycling, and swimming and also during training in sports like field hockey and football. Basic questions associated with tracking data include how often, much, or hard an individual or a group trains, and a more advanced outlook tries to explain the impact of training on athlete physiology or performance. %% tools: commercial, GC Tools for basic analytics are usually offered by the manufacturers of the tracking devices, such as Garmin, Polar, and Catapult, and through a wide range of applications for devices such as smartphones and smartwatches, e.g., Strava Running and Cycling GPS, Endomondo -- Running \& Walking, and Runtastic Running GPS Tracker. A notable open-source effort is Golden Cheetah (\url{http://www.goldencheetah.org}), which has now, perhaps, become the gold standard in terms of facilities for importing tracking data from cycling activities and for associated analytics. However, Golden Cheetah is not designed to offer general flexibility in the statistical analysis of such sports tracking data. %% tools: R in general The \proglang{R} system for statistical computing \citep{trackeR:R} with its ecosystem of add-on packages provides a wide range of possibilities for the handling and analysis of tracking data. %% other packages for trajectory data GPS-enabled tracking devices typically record irregularly sampled spatio-temporal data. Infrastructure for such data is provided in the \pkg{trajectories} package \citep{trackeR:pkg:trajectories}, which is developed around the \class{STIDF} class of the \pkg{spacetime} package \citep{trackeR:Pebesma:2012}. However, the \class{STIDF} class does not accommodate missing values in positional or temporal information. Since this is commonly the case in data from GPS-enabled tracking devices (e.g., sequences of missing values in the positional data because the GPS signal is temporarily lost), a different approach is taken in \pkg{trackeR} (see Section~\ref{sec:trackeRdata}). % Other packages that offer tools for spatio-temporal data include \pkg{adehabtitatLT} \citep{trackeR:Calenge:2006}, \pkg{trip} \citep{trackeR:pkg:trip} and \pkg{move} \citep{trackeR:pkg:move}. The main focus of those packages is on animal tracking, e.g., estimation of habitat choices, and they are not directly suitable for tracking the various aspects of athlete activity. %% Sports-related packages in \proglang{R} Despite the wide range of \proglang{R} packages available, there is only a handful of packages specific to sport data and their analysis. The available packages focus on topics such as sports management \citep[\pkg{RcmdrPlugin.SM},][]{trackeR:pkg:RcmdrPlugin.SM}, ranking sports teams \citep[\pkg{mvglmmRank},][]{trackeR:pkg:mvglmmRank}, and accessing betting odds \citep[\pkg{pinnacle.API},][]{trackeR:pkg:pinnacle.API}. \linebreak \pkg{SportsAnalytics} is a package that focuses on the analysis of performance data, and currently offers only ``a selection of data sets, functions to fetch sports data, examples, and demos'' \citep{trackeR:pkg:SportsAnalytics}. % The \pkg{cycleRtools} package \citep{trackeR:pkg:cycleRtools} provides functionality to import cycling data into \proglang{R} as well as tools for cycling-specific, descriptive analyses. %% trackeR The \pkg{trackeR} package aims to fill the gap between the routine collection of data from GPS-enabled tracking devices and the analyses of such data within the \proglang{R} ecosystem. The package provides utilities to import sports data from GPS-enabled devices, and, after careful processing, organises them in data objects which are organised in separate sessions/workouts and carry information about the units of measurement (e.g., distance and speed units) as well as of any data operations that have been carried out (e.g., smoothing). The package also implements core infrastructure for the handling of measurement units and for summarising and visualising tracking data. It also provides functionality for calculating time in zones \citep[e.g.,][]{trackeR:Seiler+Kjerland:2006}, work capacity $W'$ \citep{trackeR:Skiba+Chidnok+Vanhatalo:2012}, and distribution and concentration profiles \citep{trackeR:Kosmidis+Passfield:2015}, including a few methods for the analysis of these profiles. %% paper structure Section~\ref{sec:pkgstructure} gives an overview of the package and introduces the basic objects and the methods that apply to them. Section~\ref{sec:import} describes the importing utilities, and Section~\ref{sec:trackeRdata} details the structure and construction of the \class{trackeRdata} object, which is at the core of \pkg{trackeR}. Section~\ref{sec:summaries} is devoted to the calculation of relevant summaries (time in zones, work capacity, distribution and concentration profiles) and the corresponding methods for visualisation. Section~\ref{sec:units} and Section~\ref{sec:smoothing} focus on basic methods for unit manipulation as well as smoothing and thresholding. The case study in Section~\ref{sec:casestudy} investigates the key features in \Sexpr{nsessions(runs)} sessions through a functional principal components analysis \citep[e.g.,][]{trackeR:Ramsay+Silverman:2005} on the concentration profiles for speed. \newpage \section{Package structure}\label{sec:pkgstructure} Figures~\ref{fig:pkgstructure:read} and~\ref{fig:pkgstructure:rest} show a schematic overview of the package structure, split into two parts for reading data and further operations. Squared boxes indicate objects of a particular class, diamonds indicate files of a particular format, and boxes with rounded corners represent methods that apply to those objects. The respective class and method names are given in the boxes. An arrow from an object/file type to a method indicates that the method applies to objects of the respective class; an arrow from a method to an object indicates that the method outputs objects of the respective class. A bi-directional arrow between a method and an object indicates that the method's input and output are of the same class, such as the method \fct{threshold} and objects of class \class{trackeRdata}. Arrows to or from groups of boxes apply to each box in the group. For example, the method \fct{changeUnits} applies to objects of classes \class{trackeRdataZones}, \class{trackeRdataSummary}, \class{trackeRWprime}, \class{distrProfile}, and \class{conProfile}. % \begin{figure}[t] \centering {\scriptsize \ifx\du\undefined \newlength{\du} \fi \setlength{\du}{10\unitlength} \begin{tikzpicture} \pgftransformxscale{1.000000} \pgftransformyscale{-1.000000} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{10.721112\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{14.031222\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{14.488253\du}{4.744720\du}}{\pgfpoint{14.858749\du}{5.216819\du}}{\pgfpoint{14.858749\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{14.858749\du}{6.381547\du}}{\pgfpoint{14.488253\du}{6.853646\du}}{\pgfpoint{14.031222\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{10.721112\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{10.264081\du}{6.853646\du}}{\pgfpoint{9.893584\du}{6.381547\du}}{\pgfpoint{9.893584\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{9.893584\du}{5.216819\du}}{\pgfpoint{10.264081\du}{4.744720\du}}{\pgfpoint{10.721112\du}{4.744720\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{10.721112\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{14.031222\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{14.488253\du}{4.744720\du}}{\pgfpoint{14.858749\du}{5.216819\du}}{\pgfpoint{14.858749\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{14.858749\du}{6.381547\du}}{\pgfpoint{14.488253\du}{6.853646\du}}{\pgfpoint{14.031222\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{10.721112\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{10.264081\du}{6.853646\du}}{\pgfpoint{9.893584\du}{6.381547\du}}{\pgfpoint{9.893584\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{9.893584\du}{5.216819\du}}{\pgfpoint{10.264081\du}{4.744720\du}}{\pgfpoint{10.721112\du}{4.744720\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (12.376167\du,5.905016\du){readTCX}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (18.908243\du,8.754150\du)--(18.908243\du,11.160223\du)--(23.622422\du,11.160223\du)--(23.622422\du,8.754150\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (18.908243\du,8.754150\du)--(18.908243\du,11.160223\du)--(23.622422\du,11.160223\du)--(23.622422\du,8.754150\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (21.265333\du,10.058020\du){data.frame}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{19.313083\du}{13.047147\du}} \pgfpathlineto{\pgfpoint{23.217642\du}{13.047147\du}} \pgfpathcurveto{\pgfpoint{23.756749\du}{13.047147\du}}{\pgfpoint{24.193782\du}{13.609905\du}}{\pgfpoint{24.193782\du}{14.304104\du}} \pgfpathcurveto{\pgfpoint{24.193782\du}{14.998303\du}}{\pgfpoint{23.756749\du}{15.561062\du}}{\pgfpoint{23.217642\du}{15.561062\du}} \pgfpathlineto{\pgfpoint{19.313083\du}{15.561062\du}} \pgfpathcurveto{\pgfpoint{18.773975\du}{15.561062\du}}{\pgfpoint{18.336943\du}{14.998303\du}}{\pgfpoint{18.336943\du}{14.304104\du}} \pgfpathcurveto{\pgfpoint{18.336943\du}{13.609905\du}}{\pgfpoint{18.773975\du}{13.047147\du}}{\pgfpoint{19.313083\du}{13.047147\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{19.313083\du}{13.047147\du}} \pgfpathlineto{\pgfpoint{23.217642\du}{13.047147\du}} \pgfpathcurveto{\pgfpoint{23.756749\du}{13.047147\du}}{\pgfpoint{24.193782\du}{13.609905\du}}{\pgfpoint{24.193782\du}{14.304104\du}} \pgfpathcurveto{\pgfpoint{24.193782\du}{14.998303\du}}{\pgfpoint{23.756749\du}{15.561062\du}}{\pgfpoint{23.217642\du}{15.561062\du}} \pgfpathlineto{\pgfpoint{19.313083\du}{15.561062\du}} \pgfpathcurveto{\pgfpoint{18.773975\du}{15.561062\du}}{\pgfpoint{18.336943\du}{14.998303\du}}{\pgfpoint{18.336943\du}{14.304104\du}} \pgfpathcurveto{\pgfpoint{18.336943\du}{13.609905\du}}{\pgfpoint{18.773975\du}{13.047147\du}}{\pgfpoint{19.313083\du}{13.047147\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (21.265362\du,14.409937\du){trackeRdata}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (18.282643\du,17.687100\du)--(18.282643\du,20.607669\du)--(24.248086\du,20.607669\du)--(24.248086\du,17.687100\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (18.282643\du,17.687100\du)--(18.282643\du,20.607669\du)--(24.248086\du,20.607669\du)--(24.248086\du,17.687100\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (21.265364\du,19.248218\du){trackeRdata}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{5.950199\du}{10.515309\du}} \pgfpathlineto{\pgfpoint{10.034841\du}{10.515309\du}} \pgfpathcurveto{\pgfpoint{10.598813\du}{10.515309\du}}{\pgfpoint{11.056002\du}{11.020224\du}}{\pgfpoint{11.056002\du}{11.643069\du}} \pgfpathcurveto{\pgfpoint{11.056002\du}{12.265914\du}}{\pgfpoint{10.598813\du}{12.770829\du}}{\pgfpoint{10.034841\du}{12.770829\du}} \pgfpathlineto{\pgfpoint{5.950199\du}{12.770829\du}} \pgfpathcurveto{\pgfpoint{5.386227\du}{12.770829\du}}{\pgfpoint{4.929038\du}{12.265914\du}}{\pgfpoint{4.929038\du}{11.643069\du}} \pgfpathcurveto{\pgfpoint{4.929038\du}{11.020224\du}}{\pgfpoint{5.386227\du}{10.515309\du}}{\pgfpoint{5.950199\du}{10.515309\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{5.950199\du}{10.515309\du}} \pgfpathlineto{\pgfpoint{10.034841\du}{10.515309\du}} \pgfpathcurveto{\pgfpoint{10.598813\du}{10.515309\du}}{\pgfpoint{11.056002\du}{11.020224\du}}{\pgfpoint{11.056002\du}{11.643069\du}} \pgfpathcurveto{\pgfpoint{11.056002\du}{12.265914\du}}{\pgfpoint{10.598813\du}{12.770829\du}}{\pgfpoint{10.034841\du}{12.770829\du}} \pgfpathlineto{\pgfpoint{5.950199\du}{12.770829\du}} \pgfpathcurveto{\pgfpoint{5.386227\du}{12.770829\du}}{\pgfpoint{4.929038\du}{12.265914\du}}{\pgfpoint{4.929038\du}{11.643069\du}} \pgfpathcurveto{\pgfpoint{4.929038\du}{11.020224\du}}{\pgfpoint{5.386227\du}{10.515309\du}}{\pgfpoint{5.950199\du}{10.515309\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (7.992520\du,11.748903\du){readContainer}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{16.600717\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{19.910827\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{20.367858\du}{4.744720\du}}{\pgfpoint{20.738354\du}{5.216819\du}}{\pgfpoint{20.738354\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{20.738354\du}{6.381547\du}}{\pgfpoint{20.367858\du}{6.853646\du}}{\pgfpoint{19.910827\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{16.600717\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{16.143686\du}{6.853646\du}}{\pgfpoint{15.773190\du}{6.381547\du}}{\pgfpoint{15.773190\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{15.773190\du}{5.216819\du}}{\pgfpoint{16.143686\du}{4.744720\du}}{\pgfpoint{16.600717\du}{4.744720\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{16.600717\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{19.910827\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{20.367858\du}{4.744720\du}}{\pgfpoint{20.738354\du}{5.216819\du}}{\pgfpoint{20.738354\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{20.738354\du}{6.381547\du}}{\pgfpoint{20.367858\du}{6.853646\du}}{\pgfpoint{19.910827\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{16.600717\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{16.143686\du}{6.853646\du}}{\pgfpoint{15.773190\du}{6.381547\du}}{\pgfpoint{15.773190\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{15.773190\du}{5.216819\du}}{\pgfpoint{16.143686\du}{4.744720\du}}{\pgfpoint{16.600717\du}{4.744720\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (18.255772\du,5.905016\du){readDB3}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{28.232621\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{31.542731\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{31.999762\du}{4.744720\du}}{\pgfpoint{32.370258\du}{5.216819\du}}{\pgfpoint{32.370258\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{32.370258\du}{6.381547\du}}{\pgfpoint{31.999762\du}{6.853646\du}}{\pgfpoint{31.542731\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{28.232621\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{27.775590\du}{6.853646\du}}{\pgfpoint{27.405094\du}{6.381547\du}}{\pgfpoint{27.405094\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{27.405094\du}{5.216819\du}}{\pgfpoint{27.775590\du}{4.744720\du}}{\pgfpoint{28.232621\du}{4.744720\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.498039, 0.498039, 0.498039} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{28.232621\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{31.542731\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{31.999762\du}{4.744720\du}}{\pgfpoint{32.370258\du}{5.216819\du}}{\pgfpoint{32.370258\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{32.370258\du}{6.381547\du}}{\pgfpoint{31.999762\du}{6.853646\du}}{\pgfpoint{31.542731\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{28.232621\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{27.775590\du}{6.853646\du}}{\pgfpoint{27.405094\du}{6.381547\du}}{\pgfpoint{27.405094\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{27.405094\du}{5.216819\du}}{\pgfpoint{27.775590\du}{4.744720\du}}{\pgfpoint{28.232621\du}{4.744720\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (29.887676\du,5.905016\du){}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (12.376167\du,3.630929\du)--(12.376167\du,4.723586\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (18.255743\du,3.316490\du)--(18.255759\du,4.723612\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.498039, 0.498039, 0.498039} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.498039, 0.498039, 0.498039} \pgfsetstrokecolor{dialinecolor} \draw (29.887689\du,3.316038\du)--(29.887682\du,4.724629\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (14.418331\du,6.754427\du)--(18.895467\du,8.848656\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (19.033144\du,6.873199\du)--(20.379952\du,8.733946\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.498039, 0.498039, 0.498039} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.498039, 0.498039, 0.498039} \pgfsetstrokecolor{dialinecolor} \draw (27.874182\du,6.770162\du)--(23.641950\du,8.811096\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (18.255772\du,1.030938\du)--(18.255772\du,0.598385\du)--(7.992520\du,0.598385\du)--(7.992520\du,10.497076\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (7.992520\du,12.790885\du)--(7.992520\du,19.147385\du)--(18.263096\du,19.147385\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (21.265341\du,11.180818\du)--(21.265354\du,13.025817\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (21.265363\du,15.581732\du)--(21.265364\du,17.666377\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (9.881535\du,2.347835\du)--(9.013680\du,2.347835\du)--(9.013680\du,10.515309\du); }} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (24.102548\du,1.084742\du)--(26.577179\du,2.347835\du)--(24.102548\du,3.610929\du)--(21.627916\du,2.347835\du)--cycle; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (24.102548\du,1.084742\du)--(26.577179\du,2.347835\du)--(24.102548\du,3.610929\du)--(21.627916\du,2.347835\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (24.102548\du,2.448669\du){JSON file}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{22.459995\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{25.770104\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{26.227135\du}{4.744720\du}}{\pgfpoint{26.597632\du}{5.216819\du}}{\pgfpoint{26.597632\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{26.597632\du}{6.381547\du}}{\pgfpoint{26.227135\du}{6.853646\du}}{\pgfpoint{25.770104\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{22.459995\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{22.002964\du}{6.853646\du}}{\pgfpoint{21.632467\du}{6.381547\du}}{\pgfpoint{21.632467\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{21.632467\du}{5.216819\du}}{\pgfpoint{22.002964\du}{4.744720\du}}{\pgfpoint{22.459995\du}{4.744720\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{22.459995\du}{4.744720\du}} \pgfpathlineto{\pgfpoint{25.770104\du}{4.744720\du}} \pgfpathcurveto{\pgfpoint{26.227135\du}{4.744720\du}}{\pgfpoint{26.597632\du}{5.216819\du}}{\pgfpoint{26.597632\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{26.597632\du}{6.381547\du}}{\pgfpoint{26.227135\du}{6.853646\du}}{\pgfpoint{25.770104\du}{6.853646\du}} \pgfpathlineto{\pgfpoint{22.459995\du}{6.853646\du}} \pgfpathcurveto{\pgfpoint{22.002964\du}{6.853646\du}}{\pgfpoint{21.632467\du}{6.381547\du}}{\pgfpoint{21.632467\du}{5.799183\du}} \pgfpathcurveto{\pgfpoint{21.632467\du}{5.216819\du}}{\pgfpoint{22.002964\du}{4.744720\du}}{\pgfpoint{22.459995\du}{4.744720\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (24.115050\du,5.905016\du){readJSON}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (24.109220\du,3.627032\du)--(24.115050\du,4.744720\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (23.378965\du,6.873199\du)--(22.103689\du,8.733946\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (24.102548\du,1.064742\du)--(24.102548\du,0.079907\du)--(6.971359\du,0.079907\du)--(6.971359\du,10.515309\du); }} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (18.238111\du,1.084742\du)--(20.712743\du,2.347835\du)--(18.238111\du,3.610929\du)--(15.763480\du,2.347835\du)--cycle; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (18.238111\du,1.084742\du)--(20.712743\du,2.347835\du)--(18.238111\du,3.610929\du)--(15.763480\du,2.347835\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (18.238111\du,2.448669\du){db3 file}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (12.376167\du,1.084742\du)--(14.850798\du,2.347835\du)--(12.376167\du,3.610929\du)--(9.901535\du,2.347835\du)--cycle; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (12.376167\du,1.084742\du)--(14.850798\du,2.347835\du)--(12.376167\du,3.610929\du)--(9.901535\du,2.347835\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (12.376167\du,2.448669\du){tcx file}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (29.875265\du,1.084742\du)--(32.349897\du,2.347835\du)--(29.875265\du,3.610929\du)--(27.400634\du,2.347835\du)--cycle; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.498039, 0.498039, 0.498039} \pgfsetstrokecolor{dialinecolor} \draw (29.875265\du,1.084742\du)--(32.349897\du,2.347835\du)--(29.875265\du,3.610929\du)--(27.400634\du,2.347835\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (29.875265\du,2.448669\du){}; \end{tikzpicture} } \caption{Package structure - Functionality to read tracking data.} \label{fig:pkgstructure:read} \end{figure} % % \begin{figure}[t] \centering {\scriptsize \ifx\du\undefined \newlength{\du} \fi \setlength{\du}{10\unitlength} \begin{tikzpicture} \pgftransformxscale{1.000000} \pgftransformyscale{-1.000000} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfsetlinewidth{0.100000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (6.318502\du,25.785857\du)--(6.318502\du,38.563603\du)--(31.981615\du,38.563603\du)--(31.981615\du,25.785857\du)--cycle; \pgfsetlinewidth{0.100000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (21.061772\du,26.977961\du)--(21.061772\du,37.431794\du)--(30.793454\du,37.431794\du)--(30.793454\du,26.977961\du)--cycle; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (13.535800\du,13.560587\du)--(13.535800\du,16.481156\du)--(19.501243\du,16.481156\du)--(19.501243\du,13.560587\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.535800\du,13.560587\du)--(13.535800\du,16.481156\du)--(19.501243\du,16.481156\du)--(19.501243\du,13.560587\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (16.518521\du,15.121705\du){trackeRdata}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{9.592583\du}{21.454699\du}} \pgfpathlineto{\pgfpoint{13.353466\du}{21.454699\du}} \pgfpathcurveto{\pgfpoint{13.872736\du}{21.454699\du}}{\pgfpoint{14.293687\du}{21.908725\du}}{\pgfpoint{14.293687\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{14.293687\du}{23.028865\du}}{\pgfpoint{13.872736\du}{23.482890\du}}{\pgfpoint{13.353466\du}{23.482890\du}} \pgfpathlineto{\pgfpoint{9.592583\du}{23.482890\du}} \pgfpathcurveto{\pgfpoint{9.073313\du}{23.482890\du}}{\pgfpoint{8.652362\du}{23.028865\du}}{\pgfpoint{8.652362\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{8.652362\du}{21.908725\du}}{\pgfpoint{9.073313\du}{21.454699\du}}{\pgfpoint{9.592583\du}{21.454699\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{9.592583\du}{21.454699\du}} \pgfpathlineto{\pgfpoint{13.353466\du}{21.454699\du}} \pgfpathcurveto{\pgfpoint{13.872736\du}{21.454699\du}}{\pgfpoint{14.293687\du}{21.908725\du}}{\pgfpoint{14.293687\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{14.293687\du}{23.028865\du}}{\pgfpoint{13.872736\du}{23.482890\du}}{\pgfpoint{13.353466\du}{23.482890\du}} \pgfpathlineto{\pgfpoint{9.592583\du}{23.482890\du}} \pgfpathcurveto{\pgfpoint{9.073313\du}{23.482890\du}}{\pgfpoint{8.652362\du}{23.028865\du}}{\pgfpoint{8.652362\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{8.652362\du}{21.908725\du}}{\pgfpoint{9.073313\du}{21.454699\du}}{\pgfpoint{9.592583\du}{21.454699\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (11.473025\du,22.574628\du){summary}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{24.923273\du}{17.967731\du}} \pgfpathlineto{\pgfpoint{30.694545\du}{17.967731\du}} \pgfpathcurveto{\pgfpoint{31.491392\du}{17.967731\du}}{\pgfpoint{32.137363\du}{18.420611\du}}{\pgfpoint{32.137363\du}{18.979267\du}} \pgfpathcurveto{\pgfpoint{32.137363\du}{19.537924\du}}{\pgfpoint{31.491392\du}{19.990804\du}}{\pgfpoint{30.694545\du}{19.990804\du}} \pgfpathlineto{\pgfpoint{24.923273\du}{19.990804\du}} \pgfpathcurveto{\pgfpoint{24.126426\du}{19.990804\du}}{\pgfpoint{23.480455\du}{19.537924\du}}{\pgfpoint{23.480455\du}{18.979267\du}} \pgfpathcurveto{\pgfpoint{23.480455\du}{18.420611\du}}{\pgfpoint{24.126426\du}{17.967731\du}}{\pgfpoint{24.923273\du}{17.967731\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{24.923273\du}{17.967731\du}} \pgfpathlineto{\pgfpoint{30.694545\du}{17.967731\du}} \pgfpathcurveto{\pgfpoint{31.491392\du}{17.967731\du}}{\pgfpoint{32.137363\du}{18.420611\du}}{\pgfpoint{32.137363\du}{18.979267\du}} \pgfpathcurveto{\pgfpoint{32.137363\du}{19.537924\du}}{\pgfpoint{31.491392\du}{19.990804\du}}{\pgfpoint{30.694545\du}{19.990804\du}} \pgfpathlineto{\pgfpoint{24.923273\du}{19.990804\du}} \pgfpathcurveto{\pgfpoint{24.126426\du}{19.990804\du}}{\pgfpoint{23.480455\du}{19.537924\du}}{\pgfpoint{23.480455\du}{18.979267\du}} \pgfpathcurveto{\pgfpoint{23.480455\du}{18.420611\du}}{\pgfpoint{24.126426\du}{17.967731\du}}{\pgfpoint{24.923273\du}{17.967731\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (27.808909\du,19.085101\du){distributionProfile}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{15.217776\du}{18.992770\du}} \pgfpathlineto{\pgfpoint{18.882417\du}{18.992770\du}} \pgfpathcurveto{\pgfpoint{19.388398\du}{18.992770\du}}{\pgfpoint{19.798577\du}{19.449279\du}}{\pgfpoint{19.798577\du}{20.012412\du}} \pgfpathcurveto{\pgfpoint{19.798577\du}{20.575545\du}}{\pgfpoint{19.388398\du}{21.032054\du}}{\pgfpoint{18.882417\du}{21.032054\du}} \pgfpathlineto{\pgfpoint{15.217776\du}{21.032054\du}} \pgfpathcurveto{\pgfpoint{14.711794\du}{21.032054\du}}{\pgfpoint{14.301616\du}{20.575545\du}}{\pgfpoint{14.301616\du}{20.012412\du}} \pgfpathcurveto{\pgfpoint{14.301616\du}{19.449279\du}}{\pgfpoint{14.711794\du}{18.992770\du}}{\pgfpoint{15.217776\du}{18.992770\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{15.217776\du}{18.992770\du}} \pgfpathlineto{\pgfpoint{18.882417\du}{18.992770\du}} \pgfpathcurveto{\pgfpoint{19.388398\du}{18.992770\du}}{\pgfpoint{19.798577\du}{19.449279\du}}{\pgfpoint{19.798577\du}{20.012412\du}} \pgfpathcurveto{\pgfpoint{19.798577\du}{20.575545\du}}{\pgfpoint{19.388398\du}{21.032054\du}}{\pgfpoint{18.882417\du}{21.032054\du}} \pgfpathlineto{\pgfpoint{15.217776\du}{21.032054\du}} \pgfpathcurveto{\pgfpoint{14.711794\du}{21.032054\du}}{\pgfpoint{14.301616\du}{20.575545\du}}{\pgfpoint{14.301616\du}{20.012412\du}} \pgfpathcurveto{\pgfpoint{14.301616\du}{19.449279\du}}{\pgfpoint{14.711794\du}{18.992770\du}}{\pgfpoint{15.217776\du}{18.992770\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (17.050096\du,20.118245\du){zones}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (7.268120\du,30.759088\du)--(7.268120\du,33.642589\du)--(15.650000\du,33.642589\du)--(15.650000\du,30.759088\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (7.268120\du,30.759088\du)--(7.268120\du,33.642589\du)--(15.650000\du,33.642589\du)--(15.650000\du,30.759088\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (11.459060\du,32.301672\du){trackeRdataSummary}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{11.676687\du}{8.598449\du}} \pgfpathlineto{\pgfpoint{15.548599\du}{8.598449\du}} \pgfpathcurveto{\pgfpoint{16.083199\du}{8.598449\du}}{\pgfpoint{16.516577\du}{9.038624\du}}{\pgfpoint{16.516577\du}{9.581608\du}} \pgfpathcurveto{\pgfpoint{16.516577\du}{10.124591\du}}{\pgfpoint{16.083199\du}{10.564766\du}}{\pgfpoint{15.548599\du}{10.564766\du}} \pgfpathlineto{\pgfpoint{11.676687\du}{10.564766\du}} \pgfpathcurveto{\pgfpoint{11.142087\du}{10.564766\du}}{\pgfpoint{10.708709\du}{10.124591\du}}{\pgfpoint{10.708709\du}{9.581608\du}} \pgfpathcurveto{\pgfpoint{10.708709\du}{9.038624\du}}{\pgfpoint{11.142087\du}{8.598449\du}}{\pgfpoint{11.676687\du}{8.598449\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{11.676687\du}{8.598449\du}} \pgfpathlineto{\pgfpoint{15.548599\du}{8.598449\du}} \pgfpathcurveto{\pgfpoint{16.083199\du}{8.598449\du}}{\pgfpoint{16.516577\du}{9.038624\du}}{\pgfpoint{16.516577\du}{9.581608\du}} \pgfpathcurveto{\pgfpoint{16.516577\du}{10.124591\du}}{\pgfpoint{16.083199\du}{10.564766\du}}{\pgfpoint{15.548599\du}{10.564766\du}} \pgfpathlineto{\pgfpoint{11.676687\du}{10.564766\du}} \pgfpathcurveto{\pgfpoint{11.142087\du}{10.564766\du}}{\pgfpoint{10.708709\du}{10.124591\du}}{\pgfpoint{10.708709\du}{9.581608\du}} \pgfpathcurveto{\pgfpoint{10.708709\du}{9.038624\du}}{\pgfpoint{11.142087\du}{8.598449\du}}{\pgfpoint{11.676687\du}{8.598449\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (13.612643\du,9.687441\du){plotRoute}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{19.682823\du}{8.480917\du}} \pgfpathlineto{\pgfpoint{23.273880\du}{8.480917\du}} \pgfpathcurveto{\pgfpoint{23.769702\du}{8.480917\du}}{\pgfpoint{24.171644\du}{8.963647\du}}{\pgfpoint{24.171644\du}{9.559125\du}} \pgfpathcurveto{\pgfpoint{24.171644\du}{10.154603\du}}{\pgfpoint{23.769702\du}{10.637333\du}}{\pgfpoint{23.273880\du}{10.637333\du}} \pgfpathlineto{\pgfpoint{19.682823\du}{10.637333\du}} \pgfpathcurveto{\pgfpoint{19.187002\du}{10.637333\du}}{\pgfpoint{18.785059\du}{10.154603\du}}{\pgfpoint{18.785059\du}{9.559125\du}} \pgfpathcurveto{\pgfpoint{18.785059\du}{8.963647\du}}{\pgfpoint{19.187002\du}{8.480917\du}}{\pgfpoint{19.682823\du}{8.480917\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{19.682823\du}{8.480917\du}} \pgfpathlineto{\pgfpoint{23.273880\du}{8.480917\du}} \pgfpathcurveto{\pgfpoint{23.769702\du}{8.480917\du}}{\pgfpoint{24.171644\du}{8.963647\du}}{\pgfpoint{24.171644\du}{9.559125\du}} \pgfpathcurveto{\pgfpoint{24.171644\du}{10.154603\du}}{\pgfpoint{23.769702\du}{10.637333\du}}{\pgfpoint{23.273880\du}{10.637333\du}} \pgfpathlineto{\pgfpoint{19.682823\du}{10.637333\du}} \pgfpathcurveto{\pgfpoint{19.187002\du}{10.637333\du}}{\pgfpoint{18.785059\du}{10.154603\du}}{\pgfpoint{18.785059\du}{9.559125\du}} \pgfpathcurveto{\pgfpoint{18.785059\du}{8.963647\du}}{\pgfpoint{19.187002\du}{8.480917\du}}{\pgfpoint{19.682823\du}{8.480917\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (21.478352\du,9.664958\du){threshold}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{21.387720\du}{21.449153\du}} \pgfpathlineto{\pgfpoint{25.052360\du}{21.449153\du}} \pgfpathcurveto{\pgfpoint{25.558342\du}{21.449153\du}}{\pgfpoint{25.968521\du}{21.905662\du}}{\pgfpoint{25.968521\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{25.968521\du}{23.031928\du}}{\pgfpoint{25.558342\du}{23.488436\du}}{\pgfpoint{25.052360\du}{23.488436\du}} \pgfpathlineto{\pgfpoint{21.387720\du}{23.488436\du}} \pgfpathcurveto{\pgfpoint{20.881738\du}{23.488436\du}}{\pgfpoint{20.471560\du}{23.031928\du}}{\pgfpoint{20.471560\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{20.471560\du}{21.905662\du}}{\pgfpoint{20.881738\du}{21.449153\du}}{\pgfpoint{21.387720\du}{21.449153\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{21.387720\du}{21.449153\du}} \pgfpathlineto{\pgfpoint{25.052360\du}{21.449153\du}} \pgfpathcurveto{\pgfpoint{25.558342\du}{21.449153\du}}{\pgfpoint{25.968521\du}{21.905662\du}}{\pgfpoint{25.968521\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{25.968521\du}{23.031928\du}}{\pgfpoint{25.558342\du}{23.488436\du}}{\pgfpoint{25.052360\du}{23.488436\du}} \pgfpathlineto{\pgfpoint{21.387720\du}{23.488436\du}} \pgfpathcurveto{\pgfpoint{20.881738\du}{23.488436\du}}{\pgfpoint{20.471560\du}{23.031928\du}}{\pgfpoint{20.471560\du}{22.468795\du}} \pgfpathcurveto{\pgfpoint{20.471560\du}{21.905662\du}}{\pgfpoint{20.881738\du}{21.449153\du}}{\pgfpoint{21.387720\du}{21.449153\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (23.220040\du,22.574628\du){Wprime}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (12.122100\du,26.953290\du)--(12.122100\du,29.875345\du)--(19.100000\du,29.875345\du)--(19.100000\du,26.953290\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (12.122100\du,26.953290\du)--(12.122100\du,29.875345\du)--(19.100000\du,29.875345\du)--(19.100000\du,26.953290\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (15.611050\du,28.515151\du){trackeRdataZones}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (13.504991\du,34.407800\du)--(13.504991\du,37.329856\du)--(20.315107\du,37.329856\du)--(20.315107\du,34.407800\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.504991\du,34.407800\du)--(13.504991\du,37.329856\du)--(20.315107\du,37.329856\du)--(20.315107\du,34.407800\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (16.910049\du,35.969661\du){trackeRWprime}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (21.952803\du,28.021094\du)--(21.952803\du,31.191813\du)--(28.118193\du,31.191813\du)--(28.118193\du,28.021094\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (21.952803\du,28.021094\du)--(21.952803\du,31.191813\du)--(28.118193\du,31.191813\du)--(28.118193\du,28.021094\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (25.035498\du,29.707287\du){distrProfile}; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{21.881104\du}{39.995566\du}} \pgfpathlineto{\pgfpoint{27.652377\du}{39.995566\du}} \pgfpathcurveto{\pgfpoint{28.449224\du}{39.995566\du}}{\pgfpoint{29.095195\du}{40.448446\du}}{\pgfpoint{29.095195\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{29.095195\du}{41.565759\du}}{\pgfpoint{28.449224\du}{42.018639\du}}{\pgfpoint{27.652377\du}{42.018639\du}} \pgfpathlineto{\pgfpoint{21.881104\du}{42.018639\du}} \pgfpathcurveto{\pgfpoint{21.084258\du}{42.018639\du}}{\pgfpoint{20.438286\du}{41.565759\du}}{\pgfpoint{20.438286\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{20.438286\du}{40.448446\du}}{\pgfpoint{21.084258\du}{39.995566\du}}{\pgfpoint{21.881104\du}{39.995566\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{21.881104\du}{39.995566\du}} \pgfpathlineto{\pgfpoint{27.652377\du}{39.995566\du}} \pgfpathcurveto{\pgfpoint{28.449224\du}{39.995566\du}}{\pgfpoint{29.095195\du}{40.448446\du}}{\pgfpoint{29.095195\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{29.095195\du}{41.565759\du}}{\pgfpoint{28.449224\du}{42.018639\du}}{\pgfpoint{27.652377\du}{42.018639\du}} \pgfpathlineto{\pgfpoint{21.881104\du}{42.018639\du}} \pgfpathcurveto{\pgfpoint{21.084258\du}{42.018639\du}}{\pgfpoint{20.438286\du}{41.565759\du}}{\pgfpoint{20.438286\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{20.438286\du}{40.448446\du}}{\pgfpoint{21.084258\du}{39.995566\du}}{\pgfpoint{21.881104\du}{39.995566\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (24.766741\du,41.112936\du){concentrationProfile}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (23.684746\du,32.478994\du)--(23.684746\du,35.590591\du)--(30.143597\du,35.590591\du)--(30.143597\du,32.478994\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (23.684746\du,32.478994\du)--(23.684746\du,35.590591\du)--(30.143597\du,35.590591\du)--(30.143597\du,32.478994\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (26.914172\du,34.135626\du){conProfile}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{3.418128\du}{22.200087\du}} \pgfpathlineto{\pgfpoint{6.222639\du}{22.200087\du}} \pgfpathcurveto{\pgfpoint{6.609861\du}{22.200087\du}}{\pgfpoint{6.923766\du}{22.634980\du}}{\pgfpoint{6.923766\du}{23.171448\du}} \pgfpathcurveto{\pgfpoint{6.923766\du}{23.707916\du}}{\pgfpoint{6.609861\du}{24.142809\du}}{\pgfpoint{6.222639\du}{24.142809\du}} \pgfpathlineto{\pgfpoint{3.418128\du}{24.142809\du}} \pgfpathcurveto{\pgfpoint{3.030905\du}{24.142809\du}}{\pgfpoint{2.717000\du}{23.707916\du}}{\pgfpoint{2.717000\du}{23.171448\du}} \pgfpathcurveto{\pgfpoint{2.717000\du}{22.634980\du}}{\pgfpoint{3.030905\du}{22.200087\du}}{\pgfpoint{3.418128\du}{22.200087\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{3.418128\du}{22.200087\du}} \pgfpathlineto{\pgfpoint{6.222639\du}{22.200087\du}} \pgfpathcurveto{\pgfpoint{6.609861\du}{22.200087\du}}{\pgfpoint{6.923766\du}{22.634980\du}}{\pgfpoint{6.923766\du}{23.171448\du}} \pgfpathcurveto{\pgfpoint{6.923766\du}{23.707916\du}}{\pgfpoint{6.609861\du}{24.142809\du}}{\pgfpoint{6.222639\du}{24.142809\du}} \pgfpathlineto{\pgfpoint{3.418128\du}{24.142809\du}} \pgfpathcurveto{\pgfpoint{3.030905\du}{24.142809\du}}{\pgfpoint{2.717000\du}{23.707916\du}}{\pgfpoint{2.717000\du}{23.171448\du}} \pgfpathcurveto{\pgfpoint{2.717000\du}{22.634980\du}}{\pgfpoint{3.030905\du}{22.200087\du}}{\pgfpoint{3.418128\du}{22.200087\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (4.820383\du,23.277281\du){plot}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{25.371116\du}{12.889528\du}} \pgfpathlineto{\pgfpoint{29.131999\du}{12.889528\du}} \pgfpathcurveto{\pgfpoint{29.651269\du}{12.889528\du}}{\pgfpoint{30.072220\du}{13.343554\du}}{\pgfpoint{30.072220\du}{13.903624\du}} \pgfpathcurveto{\pgfpoint{30.072220\du}{14.463694\du}}{\pgfpoint{29.651269\du}{14.917719\du}}{\pgfpoint{29.131999\du}{14.917719\du}} \pgfpathlineto{\pgfpoint{25.371116\du}{14.917719\du}} \pgfpathcurveto{\pgfpoint{24.851846\du}{14.917719\du}}{\pgfpoint{24.430895\du}{14.463694\du}}{\pgfpoint{24.430895\du}{13.903624\du}} \pgfpathcurveto{\pgfpoint{24.430895\du}{13.343554\du}}{\pgfpoint{24.851846\du}{12.889528\du}}{\pgfpoint{25.371116\du}{12.889528\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{25.371116\du}{12.889528\du}} \pgfpathlineto{\pgfpoint{29.131999\du}{12.889528\du}} \pgfpathcurveto{\pgfpoint{29.651269\du}{12.889528\du}}{\pgfpoint{30.072220\du}{13.343554\du}}{\pgfpoint{30.072220\du}{13.903624\du}} \pgfpathcurveto{\pgfpoint{30.072220\du}{14.463694\du}}{\pgfpoint{29.651269\du}{14.917719\du}}{\pgfpoint{29.131999\du}{14.917719\du}} \pgfpathlineto{\pgfpoint{25.371116\du}{14.917719\du}} \pgfpathcurveto{\pgfpoint{24.851846\du}{14.917719\du}}{\pgfpoint{24.430895\du}{14.463694\du}}{\pgfpoint{24.430895\du}{13.903624\du}} \pgfpathcurveto{\pgfpoint{24.430895\du}{13.343554\du}}{\pgfpoint{24.851846\du}{12.889528\du}}{\pgfpoint{25.371116\du}{12.889528\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (27.251558\du,14.009457\du){smoother}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{2.939941\du}{39.993007\du}} \pgfpathlineto{\pgfpoint{6.700824\du}{39.993007\du}} \pgfpathcurveto{\pgfpoint{7.220094\du}{39.993007\du}}{\pgfpoint{7.641045\du}{40.447033\du}}{\pgfpoint{7.641045\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{7.641045\du}{41.567172\du}}{\pgfpoint{7.220094\du}{42.021198\du}}{\pgfpoint{6.700824\du}{42.021198\du}} \pgfpathlineto{\pgfpoint{2.939941\du}{42.021198\du}} \pgfpathcurveto{\pgfpoint{2.420671\du}{42.021198\du}}{\pgfpoint{1.999720\du}{41.567172\du}}{\pgfpoint{1.999720\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{1.999720\du}{40.447033\du}}{\pgfpoint{2.420671\du}{39.993007\du}}{\pgfpoint{2.939941\du}{39.993007\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{2.939941\du}{39.993007\du}} \pgfpathlineto{\pgfpoint{6.700824\du}{39.993007\du}} \pgfpathcurveto{\pgfpoint{7.220094\du}{39.993007\du}}{\pgfpoint{7.641045\du}{40.447033\du}}{\pgfpoint{7.641045\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{7.641045\du}{41.567172\du}}{\pgfpoint{7.220094\du}{42.021198\du}}{\pgfpoint{6.700824\du}{42.021198\du}} \pgfpathlineto{\pgfpoint{2.939941\du}{42.021198\du}} \pgfpathcurveto{\pgfpoint{2.420671\du}{42.021198\du}}{\pgfpoint{1.999720\du}{41.567172\du}}{\pgfpoint{1.999720\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{1.999720\du}{40.447033\du}}{\pgfpoint{2.420671\du}{39.993007\du}}{\pgfpoint{2.939941\du}{39.993007\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (4.820382\du,41.112936\du){changeUnits}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (15.728202\du,13.541540\du)--(14.149159\du,10.585866\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (15.515212\du,16.501910\du)--(12.173309\du,21.435068\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (16.672180\du,16.463739\du)--(16.939395\du,18.972914\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (17.851135\du,16.501910\du)--(22.283774\du,21.428249\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (19.520287\du,16.073287\du)--(24.873298\du,17.950046\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (11.471541\du,23.502943\du)--(11.461147\du,30.746734\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (17.049622\du,21.053204\du)--(17.046956\du,26.905031\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.515156\du,16.150607\du)--(10.175175\du,17.406962\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (27.540099\du,20.009295\du)--(25.454794\du,27.999792\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (22.628185\du,31.242024\du)--(22.640559\du,39.923216\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (26.209559\du,39.995566\du)--(26.209562\du,35.636631\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.535800\du,15.751014\du)--(4.820383\du,15.751014\du)--(4.820383\du,22.180034\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (30.071636\du,13.903624\du)--(32.673310\du,13.903624\du)--(32.673310\du,28.339402\du)--(30.830412\du,28.339402\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.515695\du,15.020871\du)--(1.091019\du,15.020871\du)--(1.091019\du,41.007103\du)--(2.000597\du,41.007103\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (17.863222\du,13.540093\du)--(20.479968\du,10.658542\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (4.820383\du,24.163028\du)--(4.820383\du,28.513787\du)--(6.316770\du,28.513787\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} \pgfsetarrowsend{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (4.820382\du,39.973111\du)--(4.820382\du,33.758100\du)--(6.330400\du,33.758100\du); }} \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (19.522121\du,14.708214\du)--(24.451365\du,14.195108\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{to} {\pgfsetcornersarced{\pgfpoint{0.000000\du}{0.000000\du}}\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (16.910049\du,34.386839\du)--(16.910049\du,32.037824\du)--(19.785402\du,32.037824\du)--(19.785402\du,22.468795\du)--(20.472162\du,22.468795\du); }} \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{4.922984\du}{11.041668\du}} \pgfpathlineto{\pgfpoint{8.794897\du}{11.041668\du}} \pgfpathcurveto{\pgfpoint{9.329496\du}{11.041668\du}}{\pgfpoint{9.762875\du}{11.481843\du}}{\pgfpoint{9.762875\du}{12.024827\du}} \pgfpathcurveto{\pgfpoint{9.762875\du}{12.567810\du}}{\pgfpoint{9.329496\du}{13.007985\du}}{\pgfpoint{8.794897\du}{13.007985\du}} \pgfpathlineto{\pgfpoint{4.922984\du}{13.007985\du}} \pgfpathcurveto{\pgfpoint{4.388384\du}{13.007985\du}}{\pgfpoint{3.955006\du}{12.567810\du}}{\pgfpoint{3.955006\du}{12.024827\du}} \pgfpathcurveto{\pgfpoint{3.955006\du}{11.481843\du}}{\pgfpoint{4.388384\du}{11.041668\du}}{\pgfpoint{4.922984\du}{11.041668\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{4.922984\du}{11.041668\du}} \pgfpathlineto{\pgfpoint{8.794897\du}{11.041668\du}} \pgfpathcurveto{\pgfpoint{9.329496\du}{11.041668\du}}{\pgfpoint{9.762875\du}{11.481843\du}}{\pgfpoint{9.762875\du}{12.024827\du}} \pgfpathcurveto{\pgfpoint{9.762875\du}{12.567810\du}}{\pgfpoint{9.329496\du}{13.007985\du}}{\pgfpoint{8.794897\du}{13.007985\du}} \pgfpathlineto{\pgfpoint{4.922984\du}{13.007985\du}} \pgfpathcurveto{\pgfpoint{4.388384\du}{13.007985\du}}{\pgfpoint{3.955006\du}{12.567810\du}}{\pgfpoint{3.955006\du}{12.024827\du}} \pgfpathcurveto{\pgfpoint{3.955006\du}{11.481843\du}}{\pgfpoint{4.388384\du}{11.041668\du}}{\pgfpoint{4.922984\du}{11.041668\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (6.858940\du,12.130660\du){leafletRoute}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.516410\du,14.089728\du)--(9.402363\du,12.813702\du); } \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.042000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{10.964158\du}{40.023944\du}} \pgfpathlineto{\pgfpoint{14.836071\du}{40.023944\du}} \pgfpathcurveto{\pgfpoint{15.370670\du}{40.023944\du}}{\pgfpoint{15.804049\du}{40.464119\du}}{\pgfpoint{15.804049\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{15.804049\du}{41.550086\du}}{\pgfpoint{15.370670\du}{41.990261\du}}{\pgfpoint{14.836071\du}{41.990261\du}} \pgfpathlineto{\pgfpoint{10.964158\du}{41.990261\du}} \pgfpathcurveto{\pgfpoint{10.429558\du}{41.990261\du}}{\pgfpoint{9.996180\du}{41.550086\du}}{\pgfpoint{9.996180\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{9.996180\du}{40.464119\du}}{\pgfpoint{10.429558\du}{40.023944\du}}{\pgfpoint{10.964158\du}{40.023944\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{10.964158\du}{40.023944\du}} \pgfpathlineto{\pgfpoint{14.836071\du}{40.023944\du}} \pgfpathcurveto{\pgfpoint{15.370670\du}{40.023944\du}}{\pgfpoint{15.804049\du}{40.464119\du}}{\pgfpoint{15.804049\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{15.804049\du}{41.550086\du}}{\pgfpoint{15.370670\du}{41.990261\du}}{\pgfpoint{14.836071\du}{41.990261\du}} \pgfpathlineto{\pgfpoint{10.964158\du}{41.990261\du}} \pgfpathcurveto{\pgfpoint{10.429558\du}{41.990261\du}}{\pgfpoint{9.996180\du}{41.550086\du}}{\pgfpoint{9.996180\du}{41.007103\du}} \pgfpathcurveto{\pgfpoint{9.996180\du}{40.464119\du}}{\pgfpoint{10.429558\du}{40.023944\du}}{\pgfpoint{10.964158\du}{40.023944\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (12.900114\du,41.112936\du){timeline}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (11.460152\du,33.663358\du)--(11.464857\du,39.968075\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{6.872482\du}{17.150462\du}} \pgfpathlineto{\pgfpoint{9.676993\du}{17.150462\du}} \pgfpathcurveto{\pgfpoint{10.064215\du}{17.150462\du}}{\pgfpoint{10.378121\du}{17.585355\du}}{\pgfpoint{10.378121\du}{18.121823\du}} \pgfpathcurveto{\pgfpoint{10.378121\du}{18.658292\du}}{\pgfpoint{10.064215\du}{19.093185\du}}{\pgfpoint{9.676993\du}{19.093185\du}} \pgfpathlineto{\pgfpoint{6.872482\du}{19.093185\du}} \pgfpathcurveto{\pgfpoint{6.485260\du}{19.093185\du}}{\pgfpoint{6.171354\du}{18.658292\du}}{\pgfpoint{6.171354\du}{18.121823\du}} \pgfpathcurveto{\pgfpoint{6.171354\du}{17.585355\du}}{\pgfpoint{6.485260\du}{17.150462\du}}{\pgfpoint{6.872482\du}{17.150462\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{6.872482\du}{17.150462\du}} \pgfpathlineto{\pgfpoint{9.676993\du}{17.150462\du}} \pgfpathcurveto{\pgfpoint{10.064215\du}{17.150462\du}}{\pgfpoint{10.378121\du}{17.585355\du}}{\pgfpoint{10.378121\du}{18.121823\du}} \pgfpathcurveto{\pgfpoint{10.378121\du}{18.658292\du}}{\pgfpoint{10.064215\du}{19.093185\du}}{\pgfpoint{9.676993\du}{19.093185\du}} \pgfpathlineto{\pgfpoint{6.872482\du}{19.093185\du}} \pgfpathcurveto{\pgfpoint{6.485260\du}{19.093185\du}}{\pgfpoint{6.171354\du}{18.658292\du}}{\pgfpoint{6.171354\du}{18.121823\du}} \pgfpathcurveto{\pgfpoint{6.171354\du}{17.585355\du}}{\pgfpoint{6.485260\du}{17.150462\du}}{\pgfpoint{6.872482\du}{17.150462\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (8.274738\du,18.227657\du){nsessions}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{34.892866\du}{33.346015\du}} \pgfpathlineto{\pgfpoint{37.697377\du}{33.346015\du}} \pgfpathcurveto{\pgfpoint{38.084599\du}{33.346015\du}}{\pgfpoint{38.398504\du}{33.780908\du}}{\pgfpoint{38.398504\du}{34.317376\du}} \pgfpathcurveto{\pgfpoint{38.398504\du}{34.853845\du}}{\pgfpoint{38.084599\du}{35.288738\du}}{\pgfpoint{37.697377\du}{35.288738\du}} \pgfpathlineto{\pgfpoint{34.892866\du}{35.288738\du}} \pgfpathcurveto{\pgfpoint{34.505643\du}{35.288738\du}}{\pgfpoint{34.191738\du}{34.853845\du}}{\pgfpoint{34.191738\du}{34.317376\du}} \pgfpathcurveto{\pgfpoint{34.191738\du}{33.780908\du}}{\pgfpoint{34.505643\du}{33.346015\du}}{\pgfpoint{34.892866\du}{33.346015\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{34.892866\du}{33.346015\du}} \pgfpathlineto{\pgfpoint{37.697377\du}{33.346015\du}} \pgfpathcurveto{\pgfpoint{38.084599\du}{33.346015\du}}{\pgfpoint{38.398504\du}{33.780908\du}}{\pgfpoint{38.398504\du}{34.317376\du}} \pgfpathcurveto{\pgfpoint{38.398504\du}{34.853845\du}}{\pgfpoint{38.084599\du}{35.288738\du}}{\pgfpoint{37.697377\du}{35.288738\du}} \pgfpathlineto{\pgfpoint{34.892866\du}{35.288738\du}} \pgfpathcurveto{\pgfpoint{34.505643\du}{35.288738\du}}{\pgfpoint{34.191738\du}{34.853845\du}}{\pgfpoint{34.191738\du}{34.317376\du}} \pgfpathcurveto{\pgfpoint{34.191738\du}{33.780908\du}}{\pgfpoint{34.505643\du}{33.346015\du}}{\pgfpoint{34.892866\du}{33.346015\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (36.295121\du,34.423210\du){profile2fd}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetlinewidth{0.040000\du} \pgfsetbuttcap \pgfsetmiterjoin \pgfsetdash{}{0pt} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfpathmoveto{\pgfpoint{34.892866\du}{29.886520\du}} \pgfpathlineto{\pgfpoint{37.697377\du}{29.886520\du}} \pgfpathcurveto{\pgfpoint{38.084599\du}{29.886520\du}}{\pgfpoint{38.398504\du}{30.321413\du}}{\pgfpoint{38.398504\du}{30.857881\du}} \pgfpathcurveto{\pgfpoint{38.398504\du}{31.394349\du}}{\pgfpoint{38.084599\du}{31.829242\du}}{\pgfpoint{37.697377\du}{31.829242\du}} \pgfpathlineto{\pgfpoint{34.892866\du}{31.829242\du}} \pgfpathcurveto{\pgfpoint{34.505643\du}{31.829242\du}}{\pgfpoint{34.191738\du}{31.394349\du}}{\pgfpoint{34.191738\du}{30.857881\du}} \pgfpathcurveto{\pgfpoint{34.191738\du}{30.321413\du}}{\pgfpoint{34.505643\du}{29.886520\du}}{\pgfpoint{34.892866\du}{29.886520\du}} \pgfusepath{fill} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \pgfpathmoveto{\pgfpoint{34.892866\du}{29.886520\du}} \pgfpathlineto{\pgfpoint{37.697377\du}{29.886520\du}} \pgfpathcurveto{\pgfpoint{38.084599\du}{29.886520\du}}{\pgfpoint{38.398504\du}{30.321413\du}}{\pgfpoint{38.398504\du}{30.857881\du}} \pgfpathcurveto{\pgfpoint{38.398504\du}{31.394349\du}}{\pgfpoint{38.084599\du}{31.829242\du}}{\pgfpoint{37.697377\du}{31.829242\du}} \pgfpathlineto{\pgfpoint{34.892866\du}{31.829242\du}} \pgfpathcurveto{\pgfpoint{34.505643\du}{31.829242\du}}{\pgfpoint{34.191738\du}{31.394349\du}}{\pgfpoint{34.191738\du}{30.857881\du}} \pgfpathcurveto{\pgfpoint{34.191738\du}{30.321413\du}}{\pgfpoint{34.505643\du}{29.886520\du}}{\pgfpoint{34.892866\du}{29.886520\du}} \pgfusepath{stroke} % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (36.295121\du,30.963714\du){funPCA}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (33.065696\du,37.682045\du)--(33.065696\du,40.793641\du)--(39.524547\du,40.793641\du)--(39.524547\du,37.682045\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (33.065696\du,37.682045\du)--(33.065696\du,40.793641\du)--(39.524547\du,40.793641\du)--(39.524547\du,37.682045\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (36.295121\du,39.338676\du){fda::fd}; \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \fill (33.065696\du,24.568903\du)--(33.065696\du,27.680500\du)--(39.524547\du,27.680500\du)--(39.524547\du,24.568903\du)--cycle; \pgfsetlinewidth{0.042000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetmiterjoin \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (33.065696\du,24.568903\du)--(33.065696\du,27.680500\du)--(39.524547\du,27.680500\du)--(39.524547\du,24.568903\du)--cycle; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node at (36.295121\du,26.225535\du){trackeRfpca}; \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (36.295121\du,35.308437\du)--(36.295121\du,37.661155\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (36.295121\du,29.867565\du)--(36.295121\du,27.701465\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (30.838871\du,30.851646\du)--(34.173098\du,30.855456\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (30.788119\du,34.323956\du)--(34.171846\du,34.319913\du); } \pgfsetlinewidth{0.040000\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsend{to} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (8.273050\du,25.773979\du)--(8.274519\du,19.112905\du); } \end{tikzpicture} } \caption{Package structure - Functionality to analyse tracking data.} \label{fig:pkgstructure:rest} \end{figure} % Data in various formats are imported and stored in the central data object of \linebreak class~\class{trackeRdata} from which summaries for descriptive purposes or further analyses can be derived. Methods for visualisation and data handling are available for data objects and summary objects. A list of all functionality is provided in Tables~\ref{tab:pkg:functions:1} and~\ref{tab:pkg:functions:2}. For convenience, most camel-case function names in Tables~\ref{tab:pkg:functions:1} and~\ref{tab:pkg:functions:2} are aliased to function names were words are separated by underscores, e.g.~\fct{concentrationProfile} and \fct{concentration\_profile}, and \fct{readContainer} and \fct{read\_container}. \begin{table}[p] \centering \begin{tabular}{p{3cm} p{4cm} p{6.5cm}} \hline Function & Class & Description \\ \hline \fct{readTCX} & TCX file & read TCX file \\ \fct{readGPX} & GPX file & read GPX file \\ \fct{readDB3} & DB3 file (SQLite) & read DB3 file \\ \fct{readJSON} & Golden Cheetah's JSON file & read JSON file \\ \fct{readContainer} & TCX/GPX/DB3/JSON file & read a TCX/GPX/DB3/JSON file \\ \fct{readDirectory} & TCX/GPX/DB3/JSON files & read all TCX/GPX/DB3/JSON files in a \linebreak directory \\ \fct{trackeRdata} & \class{data.frame} & construct a \class{trackeRdata} object \\ % \fct{c} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata} & combine sessions \\ \fct{sort} & \class{trackeRdata} & sort sessions by start time \\ \fct{unique} & \class{trackeRdata} & extract unique sessions \\ \code{[]} & \class{trackeRdata} & subset sessions \\ % append % \fct{plot} & \class{trackeRdata} & plot session profiles \\ \fct{plotRoute} & \class{trackeRdata} & plot route on a static map \\ \fct{leafletRoute} & \class{trackeRdata} & plot route on an interactive map \\ \fct{threshold} & \class{trackeRdata} & apply lower and upper bounds on data range \\ \fct{smoother} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata} & smooth data by applying a summary function such as mean or median to a window \\ % \fct{getUnits} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata}, \class{trackeRdataSummary}, \class{trackeRdataZones}, \class{trackeRWprime} & access units of measurement \\ \fct{changeUnits} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata}, \class{trackeRdataSummary}, \class{trackeRdataZones}, \class{trackeRWprime} & change units of measurement \\ \fct{nsessions} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata}, \class{trackeRdataSummary}, \class{trackeRdataZones}, \class{trackeRWprime} & number of sessions \\ \fct{fortify} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata}, \class{trackeRdataSummary}, \class{trackeRWprime} & convert object into a data frame for plotting \\ % \hline \end{tabular} \caption{Functions available in the \pkg{trackeR} package (part 1).} \label{tab:pkg:functions:1} \end{table} \begin{table}[p] \centering \begin{tabular}{p{4.1cm} p{3.9cm} p{5.5cm}} \hline Function & Class & Description \\ \hline \fct{summary} & \class{trackeRdata} & summarise sessions \\ \fct{print} & \class{trackeRdata}, \class{trackeRdataSummary} & print sessions summaries \\ \fct{plot} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata}, \class{trackeRdataSummary}, \class{trackeRdataZones}, \class{trackeRfpca}, \class{trackeRWprime} \\ \fct{timeline} & \class{trackeRdata}, \class{trackeRdataSummary} & plot timeline summary \\ % \fct{zones} & \class{trackeRdata} & time spent in zones \\ % \fct{Wprime} & \class{trackeRdata} & calculate \emph{$W'$ balance} or \emph{$W'$ expended} \\ \fct{plot} & \class{trackeRWprime} & plot \emph{$W'$ balance} or \emph{$W'$ expended} \\ \fct{session\_times} & \class{trackeRdata}, \class{trackeRdataSummary} & return the start and end date and time of its session \\ \fct{session\_duration} & \class{trackeRdata}, \class{trackeRdataSummary} & return the duration of each session \\ \fct{get\_sport} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata}, \class{trackeRdataSummary}, \class{trackeRWprime} & return the sports of each session in the object \\ \fct{concentrationProfile} & \class{distrProfile}, \class{trackeRdata} & calculate concentration profiles \\ \fct{distributionProfile} & \class{trackeRdata} & calculate distribution profiles \\ % append \fct{ridges} & \class{conProfile}, \class{distrProfile}, \class{trackeRdata} & ridgeline plots of concentration/distribution profiles \\ \fct{profile2fd} & \class{conProfile}, \class{distrProfile} & convert profiles to \class{fd} class \\ \fct{funPCA} & \class{conProfile}, \class{distrProfile} & functional principal components analysis \\ % \hline \end{tabular} \caption{Functions available in the \pkg{trackeR} package (part 2).} \label{tab:pkg:functions:2} \end{table} \section{Import utilities}\label{sec:import} \pkg{trackeR} provides utilities for data in common formats from GPS-enabled tracking devices. The family of the supplied reading functions, \fct{read*}, currently includes functions for reading TCX (Training Centre XML), GPX (as exported by Strava but other versions should work, too), DB3 (for SQLite, used, e.g., by devices from GPSports) and Golden Cheetah's JSON files. These functions read the tracking data, and return a \code{data.frame} with a specific structure. The following code chunk illustrates the use of the \fct{readTCX} function using a TCX file that ships with the package and shows the name and type of variables that are present in the resulting data frame. % <>= filepath <- system.file("extdata/tcx", "2013-06-01-183220.TCX.gz", package = "trackeR") runDF <- readTCX(file = filepath, timezone = "GMT") str(runDF) @ % Power is not available in the above data frame because the data has been identified to come from a running training by regex matching its contents with a sport-determining list of keywords. Times are taken here to be in GMT. The default for argument \code{timezone} is \code{""} and is system-specific; see \code{?as.POSIXct} for details. \pkg{trackeR} can accommodate the addition of extra formats by simply authoring appropriate import functions. Such functions should take as input the path of the file to be read and return a data frame with the same structure and attributes as in the above example. \section[trackeRdata class]{\class{trackeRdata} class}\label{sec:trackeRdata} \subsection{Object structure} The core object of \pkg{trackeR} has class \class{trackeRdata}. The \class{trackeRdata} objects are session-based, unit-aware and operation-aware structures, which organise the data in a list of multivariate \code{zoo} objects \citep{trackeR:Zeileis+Grothendieck:2005} with one element per session. The observations within each session are ordered according to the time stamps as these are read from the GPS-enabled tracking devices. Each \class{trackeRdata} object has an attribute on the measurement units of the data it holds, and, if applicable, an attribute detailing the operations, such as smoothing, it has gone through. \class{trackeRdata} objects result from the constructor function \fct{trackeRdata}, which takes as input the output of the \fct{read*} functions. Apart from the allocation of observations into distinct sessions, the constructor function also performs some data processing, including basic sanity checks (for example, removing observations with negative or missing values for cumulative distance or speed), handling of measurement units, correction of distances using altitude data if required, and data imputation, discussed in Section~\ref{sec:imputation}. \subsection{Constructor function} The interface of the constructor function for class \class{trackeRdata} is \begin{Code} trackeRdata(dat, units = NULL, sport = NULL, session_threshold = 2, correct_distances = FALSE, from_distances = TRUE, country = NULL, mask = TRUE, lgap = 30, lskip = 5, m = 11, silent = FALSE) \end{Code} \code{dat} is the data frame containing the tracking data and \code{units} is used to specify the units of measurement. Table~\ref{tab:units} shows the currently supported units and notes the units that are used by default when \code{units = NULL}. The argument \code{sport} indicate the sport from which the data is coming from and must be ``running'', ``cycling'', ``swimming''. This affects the calculation of $W'$ (based on power or speed for cycling and running, respectively) and the thresholds applied before plotting the session data. The other arguments are specific to the data processing operations, which are briefly described in the following subsections. \subsection{Identifying distinct sessions} The constructor function groups the observations into sessions according to their time stamps. Specifically, the time stamps in the data from the \fct{read*} functions are first sorted, and all consecutive observations whose time stamps are no further apart from each other than a specified threshold $t^*$ are considered to belong to a distinct session. The value of $t^*$ is set via the \code{session_threshold} argument of the \fct{trackeRdata} function and it defaults to 2 hours. \subsection{Distance correction using altitude data} If the distances in the data have been calculated solely based on latitude and longitude data, without taking into account the altitude, then the distance covered can be underestimated. The \code{correct_distances} argument of the \fct{trackeRdata} function controls whether the distances should be corrected for altitude changes. If the uncorrected distance covered at time point $t_{i}$ is $d_{2,i}$, then setting \code{correct_distances = TRUE} uses the Pythagorean theorem to correct the distance covered between time point $t_{i-1}$ and time point $t_{i}$ to \begin{equation*} d_{i} - d_{i-1} = \sqrt{ (d_{2,i} - d_{2,i-1})^2 + (a_i - a_{i - 1})^2 }\, , \end{equation*} where $d_{i}$ and $a_i$ are the corrected cumulative distance and the altitude at time $t_i$, respectively. If no altitude measurements are available, these are extracted from \emph{SRTM 90m Digital Elevation Data} via the \pkg{raster} package \citep{trackeR:Hijmans:2015} using the latitude and longitude measurements. The arguments \code{country} and \code{mask} control the extraction of altitudes. \subsection{Imputation process}\label{sec:imputation} Occasionally, there is a large time difference between consecutive observations in the same session, sometimes of the order of several minutes. This can happen, for example, if the device is intentionally paused by the athlete or if the proprietary algorithm controlling the operating sampling rate of the device detects no significant change in position. For example, in the manual of a GPS device, the Forerunner$^{\copyright}$ 310XT, it is stated that \emph{``The Forerunner uses smart recording. It records key points when you change direction, speed, or heart rate''} \citep{trackeR:forerunner310XT}. In both cases, interpolating directly to get the speed or power will lead to overestimation of the total workload within those intervals. We assume that such intervals appear only when there is no significant work happening, and hence impute them with observations with zero speed (for running) or zero speed and power (for cycling). % \begin{figure}[t] \centering %% \input{imputation_speed_manual} % Graphic for TeX using PGF % Title: /home/frick/svn/EISproject/pkg/trackeR/vignettes/imputation_speed.dia % Creator: Dia v0.97.3 % CreationDate: Thu Jan 7 18:44:15 2016 % For: frick % \usepackage{tikz} % The following commands are not supported in PSTricks at present % We define them conditionally, so when they are implemented, % this pgf file will use them. \ifx\du\undefined \newlength{\du} \fi \setlength{\du}{15\unitlength} \begin{tikzpicture} \pgftransformxscale{1.000000} \pgftransformyscale{-1.000000} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000} \pgfsetfillcolor{dialinecolor} \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (7.171400\du,10.527800\du)--(7.171400\du,9.843800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (9.223400\du,9.843800\du)--(9.223400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (11.275400\du,9.843800\du)--(11.275400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (13.327400\du,9.843800\du)--(13.327400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (15.379400\du,9.843800\du)--(15.379400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (17.431400\du,9.843800\du)--(17.431400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (19.483400\du,9.843800\du)--(19.483400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (21.535400\du,9.843800\du)--(21.535400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (23.587400\du,9.843800\du)--(23.587400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (0.331400\du,2.801800\du)--(1.699400\du,2.801800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (1.699400\du,4.853800\du){$t_i$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (29.059400\du,4.853800\du){$t_{i+1}$}; \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (5.119400\du,9.843800\du)--(5.119400\du,11.895800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (25.639400\du,9.843800\du)--(25.639400\du,11.895800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (6.487400\du,11.5\du){$t_{i}^{*} + h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (8.539400\du,11.6\du){$t_{i}^{*} + 2h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (10.591400\du,11.6\du){$t_{i}^{*} + 3h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (12.643400\du,11.6\du){$t_{i}^{*} + 4h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (14.695400\du,11.6\du){$t_{i}^{*} + 5h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (16.747400\du,11.6\du){$t_{i}^{*} + 6h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (18.799400\du,11.6\du){$t_{i}^{*} + 7h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (22.903400\du,11.6\du){$t_{i}^{*} + 9h$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center, rotate = 45] at (20.851400\du,11.6\du){$t_{i}^{*} + 8h$}; \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{latex} \pgfsetarrowsend{latex} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (1.699400\du,5.537800\du)--(29.059400\du,5.537800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (1.699400\du,1.433800\du){$s_i$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (7.171400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (9.223400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (11.275400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (13.327400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (15.379400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (17.431400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (19.483400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (21.535400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (23.587400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (29.059400\du,1.433800\du){$s_{i+1}$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=west] at (15.379400\du,5.537800\du){}; \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (1.699400\du,2.117800\du)--(1.699400\du,4.169800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (29.059400\du,2.117800\du)--(29.059400\du,4.169800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (1.699400\du,12.579800\du){$t_i$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (1.699400\du,9.159800\du){$s_i$}; \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (1.699400\du,9.843800\du)--(1.699400\du,11.895800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (29.059400\du,9.159800\du){$s_{i+1}$}; \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (29.059400\du,9.843800\du)--(29.059400\du,11.895800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{latex} \pgfsetarrowsend{latex} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (1.699400\du,13.947800\du)--(5.119400\du,13.947800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \pgfsetarrowsstart{latex} \pgfsetarrowsend{latex} \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (25.639400\du,13.947800\du)--(29.059400\du,13.947800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (14.695400\du,6.905800\du){$t_{i+1} - t_i > l_{gap}$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (3.4094\du,15.315800\du){$l_{skip}$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (27.3494\du,15.315800\du){$l_{skip}$}; \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (29.059400\du,2.801800\du)--(30.427400\du,2.801800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{{\pgflinewidth}{0.200000\du}}{0cm} \pgfsetdash{{\pgflinewidth}{0.200000\du}}{0cm} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (1.699400\du,2.801800\du)--(29.059400\du,2.801800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (0.331400\du,10.527800\du)--(1.699400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{}{0pt} \pgfsetdash{}{0pt} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (29.059400\du,10.527800\du)--(30.427400\du,10.527800\du); } \pgfsetlinewidth{0.034200\du} \pgfsetdash{{\pgflinewidth}{0.200000\du}}{0cm} \pgfsetdash{{\pgflinewidth}{0.200000\du}}{0cm} \pgfsetbuttcap { \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetfillcolor{dialinecolor} % was here!!! \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \draw (1.699400\du,10.527800\du)--(29.059400\du,10.527800\du); } % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (29.059400\du,12.579800\du){$t_{i+1}$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (5.119400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (25.639400\du,9.159800\du){0}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=west] at (24.955400\du,12.579800\du){}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (4.885400\du,12.579800\du){$t_{i}^{*}$}; % setfont left to latex \definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000} \pgfsetstrokecolor{dialinecolor} \node[anchor=center] at (25.639400\du,12.579800\du){$t_{i+1}^{*}$}; \end{tikzpicture} \caption{Illustration of the imputation process for speed with $m = 11$.} \label{fig:imputation} \end{figure} % Figure~\ref{fig:imputation} shows a schematic representation of the imputation process for speed. The parameters $l_{gap}$, $m$ and $l_{skip}$ control the imputation, and can be specified via the \code{lgap}, \code{m} and \code{lskip} arguments of the \fct{trackeRdata} function, respectively. If the observations at times $t_i$ and $t_{i + 1}$ are more than $l_{gap}$ seconds apart, then it is assumed that there is no significant work happening between $t_i$ and $t_{i + 1}$. The number of imputed records in the interval is $m$, and consists of two 'outer' records and $m - 2$ 'inner' records. The 'outer' records are $l_{skip}$ seconds apart from the existing observations forming the beginning and the end of the interval, respectively. The 'inner' records are $h = (t_{i+1} - t_i - 2 l_{skip}) / (m - 1)$ seconds apart. The imputed records between $t_i$ and $t_{i + 1}$ have zero speed or power, and the latitude, longitude and altitude measurements are set to their values at time $t_i$. All other variables are set to \code{NA}. \fct{trackeRdata} also adds five records at the beginning and five at the end of a session, based on the assumption that there is no activity before and after the available records. These observations have zero speed or power, their latitude, longitude and altitude measurements are as in the first and last observations, respectively, and all other variables are set to \code{NA}. The imputed records are one second apart from each other and from the first and the last observation, respectively. After the imputation process, the cumulative distances are updated based on the imputed speeds and the time differences between consecutive observations, according to \begin{equation*} d_{i+1} = d_{i} + s_i (t_{i+1} - t_i) \end{equation*} where $s_i$ and $d_i$ denote the speed and cumulative distance at time point $t_i$, respectively. The following code chunk takes as input the raw data in the data frame \code{runDF} and constructs the corresponding \class{trackeRdata} object. <>= runTr0 <- trackeRdata(runDF) @ The \fct{print} method for \class{trackeRdata} objects displays some basic summaries about the sessions, including the sports present in the sessions, the number of sessions, training coverage, total training duration and the units for each of the variables. <>= runTr0 @ The function \fct{readContainer} is a convenience wrapper that calls the suitable reading function and, then, \fct{trackeRdata} for the data processing and the organisation of the data in a \class{trackeRdata} object (see \code{?readContainer} for the available arguments). For example, <>= runTr1 <- readContainer(filepath, type = "tcx", timezone = "GMT") identical(runTr0, runTr1) @ The function \fct{readDirectory} allows the user to read all files of a supported format in a directory, rather than calling, e.g., \fct{readContainer} on each file separately. For example, the following chunk of code will read a directory with one cycling, one running and, one swimming session, constructs the corresponding trackeRdata object, and then extracts the sports for each session. <>= gpxDir <- system.file("extdata/gpx", package = "trackeR") workouts <- readDirectory(gpxDir, verbose = FALSE) get_sport(workouts) @ Using the argument \code{aggregate}, the user can decide if all data are first combined in a data frame and then split into sessions solely based on the time difference between consecutive observations. This way, e.g., warm-up and cool-down phases are put into the same session as the central part of training, even if they are recorded in separate container files. Alternatively, data from different container files are always stored in separate sessions. % <>= data("run", package = "trackeR") data("runs", package = "trackeR") @ % \pkg{trackeR} ships with two \class{trackeRdata} objects containing \Sexpr{nsessions(run)} and \Sexpr{nsessions(runs)} running sessions, respectively, and which can be loaded via % <>= data("run", package = "trackeR") data("runs", package = "trackeR") @ % We will use those objects for the illustrations throughout the paper. %% %\pagebreak \section{Session summaries and visualisation}\label{sec:summaries} \pkg{trackeR} provides methods for summarising sessions in terms of scalar summaries, the time spent exercising in specified zones, the concept of work capacity, and distribution and concentration profiles. \subsection{Visualisation} For a first visual inspection of the data, the \fct{plot} method shows by default the evolution of heart rate and pace over the course of the selected sessions. For example, Figure~\ref{fig:defaultPlot:1} shows the evolution of heart rate and pace for the first three sessions in the \code{runs} object. %% session 3 is an interval session? mention anything about the content of the plots? % <>= plot(runs, session = 1:3) @ % \setkeys{Gin}{width=\textwidth} \begin{figure}[t] \centering % <>= plot(runs, session = 1:3) @ % \caption{Heart rate and pace over the course of sessions~1--3.} \label{fig:defaultPlot:1} \end{figure} %\clearpage The route covered during a session can also be displayed on a static map via the \fct{plotRoute} method. The \fct{plotRoute} method uses the \pkg{ggmap} package \citep{trackeR:Kahle+Wickham:2013} and, hence, can work with the sources and maps supported by \pkg{ggmap}. For example, Figure~\ref{fig:routePlot} shows the route covered during session~4 in \code{runs} using a map downloaded from Google. Interactive maps can be produced with \fct{leafletPlot}, using the \pkg{leaflet} package \citep{trackeR:pkg:leaflet}. % <>= plotRoute(runs, session = 4, zoom = 13) @ % \setkeys{Gin}{width=0.8\textwidth} \begin{figure}[t] \centering % % % <>= % plotRoute(runs, session = 4, zoom = 13) % @ % \includegraphics{plotRouteGoogle} \caption{Route covered during session~4 on a map from Google.} \label{fig:routePlot} \end{figure} \subsection{Scalar summaries} Each session can be summarised through common summary statistics using the \fct{summary} method. Such a session summary includes estimates of the total distance covered, the total duration, the time spent moving, and work to rest ratio. It also includes averages of speed, pace, cadence, power, and heart rate, calculated based on total duration or the time spent moving. An athlete is considered to be moving if the speed is larger than some threshold $s^*$. This threshold can be set via the \code{moving_threshold} argument of the \fct{summary} method, and the package assumes that anything between not moving at all and walking with a speed below that threshold is resting. The default value for \code{moving_threshold} has been set to 1~meter per second for running, which is just below the speed humans prefer to walk at on average \citep[1.4~meters per second; see][]{trackeR:Bohannon:1997}, 0.5~meter per second for swimming and 2 meters per second for cycling. The ``average speed moving'' is calculated as total distance covered divided by time moving while ``average speed'' is calculated as total distance divided by total duration. The average pace~(moving) is calculated as the inverse of the average speed~(moving). The work to rest ratio is calculated as time moving divided by (total duration - time moving). The averages for cadence, power, and heart rate (total and moving) are weighted averages with weights depending on the time difference to the next observation. These averages also need to take into account missingness in the observations. For a variable of interest $V$, we can calculate a weighted mean for the total session while accounting for missing values via \begin{equation*} \sum_{i}{v_i \frac{\Delta_i K_i}{\sum_{i}{\Delta_i K_i}}} %%\label{eq:wmean} \end{equation*} and its counterpart for the part of the session spent in motion via \begin{equation*} \sum_{i}{v_i \frac{\Delta_i K_i I(s_i > s^*)} {\sum_{i}{\Delta_i K_i I(s_i > s^*)}}} %%\label{eq:wmean:moving} \end{equation*} where $v_i$ is the value of $V$ at time point $t_i$, $K_i$ is 1 if $v_i$ is available, i.e., not missing, and 0 otherwise, $I(\cdot)$ denotes the indicator function, and $\Delta_i = t_i - t_{i-1}$ the time difference between observations at $t_i$ and $t_{i-1}$. The \fct{summary} method for \class{trackeRdata} objects returns a data frame which can be used for further analysis. The return object is classed as \class{trackeRdataSummary} for which several methods are available. With the \fct{print} method, one can set the number of digits printed for the scalar summary statistics. The following example shows the summaries for sessions~1--2 with the default number of digits of 2 and then the summary of session~1 with 3~digits for comparison. % <>= summary(runs, session = 1:2) runSummary <- summary(runs, session = 1) print(runSummary, digits = 3) @ % The \fct{plot} method shows the evolution of the various summary statistics over calendar time or over the course of the sessions. For example, the following code chunk produces Figure~\ref{fig:summaryPlot}. % <>= runSummaryFull <- summary(runs) plot(runSummaryFull, group = c("total", "moving"), what = c("avgSpeed", "distance", "duration", "avgHeartRate")) @ % \setkeys{Gin}{width=\textwidth} \begin{figure}[t] \centering % <>= runSummaryFull <- summary(runs) plot(runSummaryFull, group = c("total", "moving"), what = c("avgSpeed", "distance", "duration", "avgHeartRate")) @ % \caption{Selected session summaries for all \Sexpr{nsessions(runs)}~sessions.} \label{fig:summaryPlot} \end{figure} \subsection{Times in zones}\label{subsec:zones} A common way to summarise and characterise a session is to calculate how much time was spent exercising in certain zones, e.g., heart rate zones. The \fct{zones} method for sessions returns an object of class \class{trackeRdataZones} for which methods \fct{changeUnits} and \fct{plot} are provided. The user can specify the variables, such as heart rate and speed, and their respective zones via the arguments \code{what} and \code{breaks}, respectively. Figure~\ref{fig:zonesPlot} shows a graphical representation of the zones summary, making it easier to see that more (relative) time was spent training with high speed ($> \, 4 \, m/s$) in sessions~3 and~4 than in sessions~1 and~2. The following code chunk illustrates three equivalent ways to specify the zones for a single variable: 1) in the standard way through arguments \code{what} and \code{breaks} 2) if \code{breaks} is a named list, argument \code{what} can be left unspecified and 3) if only a single variable is to be evaluated, \code{breaks} can also be a vector. % <>= runZones <- zones(runs[1:4], what = "speed", breaks = list(speed = c(0, 2:6, 12.5))) runZones <- zones(runs[1:4], breaks = list(speed = c(0, 2:6, 12.5))) runZones <- zones(runs[1:4], what = "speed", breaks = c(0, 2:6, 12.5)) plot(runZones) @ % \setkeys{Gin}{width=0.8\textwidth} \begin{figure}[t] \centering % <>= runZones <- zones(runs[1:4], what = "speed", breaks = list(speed = c(0, 2:6, 12.5))) runZones <- zones(runs[1:4], breaks = list(speed = c(0, 2:6, 12.5))) runZones <- zones(runs[1:4], what = "speed", breaks = c(0, 2:6, 12.5)) plot(runZones) @ % \caption{Zone summaries for speed of sessions~1--4.} \label{fig:zonesPlot} \end{figure} %%\pagebreak %%% when JSS header is included \subsection{Quantifying work capacity}\label{subsec:workcapacity} The critical power model \citep{trackeR:Monod+Scherrer:1965} describes the relationship between the power output $P$ and the time $t_e$ to exhaustion at that power output % \begin{equation} \label{eq:CPmodel} P = (W'_0 / t_e) + CP \end{equation} % in terms of two parameters $W'_0$ and CP. The critical power (CP) is defined by \citet{trackeR:Monod+Scherrer:1965} as ``the maximum rate (of work) that [can be kept] up for a very long time without fatigue.'' \citet{trackeR:Skiba+Chidnok+Vanhatalo:2012} describe CP as ``a power output that could \emph{theoretically} be maintained indefinitely on the basis of principally 'aerobic' metabolism.'' $W'$ (read W~prime) represents a finite work capacity above CP. \citet{trackeR:Skiba+Chidnok+Vanhatalo:2012} assume that $W'$ gets depleted during exercise with a power output above CP but also replenished during exercise with a power output of or below CP. We denote as $W'$ the general concept of work capacity above CP, and $W'(t)$ is the state of $W'$ at time $t$. The latter is also sometimes referred to as \emph{$W'$~balance} at time $t$. Additionally, the initial state of $W'$ at the start of an exercise $t = t_0$ is $W'_0 = W'(t_0)$, which is one of the parameters in the critical power model (Equation~\ref{eq:CPmodel}). Total depletion of $W'_0$ results in the inability to produce a power output above CP. Thus, knowledge of the current state $W'(t)$, i.e., how much of that finite work capacity $W'_0$ is left at time $t$, is important to an athlete, particularly in a race. While this concept is most commonly applied to cycling, where the power output is routinely measured, \cite{trackeR:Skiba+Chidnok+Vanhatalo:2012} suggest that it can also be applied to running, substituting power and critical power by speed and critical speed, respectively. For running, the model postulates that each runner has a finite capacity in terms of distance covered above the critical speed. Depending on how much the runner exceeds this critical speed, the finite capacity $W'_0$ is being exhausted in shorter times. Below we describe the models for depletion and replenishment of work capacity and how they are combined in \pkg{trackeR}. \subsubsection{Depletion of work capacity} Assuming constant power for periods of exertion above CP, \cite{trackeR:Skiba+Fulford+Clarke:2015} assume that $W'$ is depleted at a rate directly proportional to the difference between the power output and~CP % \begin{equation} \label{eq:discharge:rate} \frac{d}{d t} W'(t) = -(P - CP) \, . \end{equation} % Solving Equation~\ref{eq:discharge:rate} for $W'(t)$ gives % \begin{equation} \label{eq:discharge} W'(t) = -(P - CP) t + D \end{equation} % where $D \in \mathds{R}$ is constant over $t$. Suppose that the exercise over time $t_0 = 0$ to $t_n = T$ can be split into $n$ intervals with breakpoints $t_0, t_1, \ldots, t_n$ such that the power output within each interval is constant, that is $P(t) = P_i$ for $t \in [t_{i-1}, t_i)$, $i \in \{ 1, \ldots, n \}$. Then, using Equation~\ref{eq:discharge}, the change in $W'(t)$ over the interval can be expressed as % \begin{align} W'(t_i) - W'(t_{i-1}) %&= - (P_i - CP) t_i + D - \left( -(P_i - CP) t_{i-1} + D \right) \nonumber \\ &= - (P_i - CP) (t_i - t_{i-1}) \, . \label{eq:discharge:interval} \end{align} % \subsubsection{Replenishing of work capacity} \cite{trackeR:Skiba+Fulford+Clarke:2015} assume that the periods with a power output at or below CP are periods of recovery during which $W'$ is replenished with a rate that depends on the difference between CP and the power output, and the amount of $W'_0$ remaining, as follows: % \begin{equation} \label{eq:recharge:rate} \frac{d}{d t} W'(t) = \left( 1 - \frac{W'(t)}{W'_0} \right) (CP - P) \, . \end{equation} % Equation~\ref{eq:recharge:rate} assumes that recovery slows down as $W'(t)$ approaches the initial capacity $W'_0$. Employing the substitution rule for integrals while solving Equation~\ref{eq:recharge:rate} and reexpressing in terms of $W'(t_{i-1})$ (see Appendix~\ref{sec:appendix} for details) gives % \begin{equation} \label{eq:recharge} W'(t_i) = W'_0 - \left( W'_0 - W'(t_{i-1}) \right) \exp \left( \frac{P_i - CP}{W'_0} (t_i - t_{i-1}) \right) \, . \end{equation} % %% Link to 2015 paper and their equation Since $W'(t_{i-1})$ is the amount of $W'_0$ remaining at the start of the interval $[t_{i-1}, t_i)$, \linebreak $W'_0 - W'(t_{i-1})$ is the amount of $W'_0$ which has been depleted prior to $t_{i-1}$ and not yet been replenished. \cite{trackeR:Skiba+Chidnok+Vanhatalo:2012} refer to this as \emph{$W'$~expended}. \cite{trackeR:Skiba+Fulford+Clarke:2015} describe the replenishing of $W'$ indirectly by describing how \emph{$W'$~expended} is reduced over the course of such a recovery interval. The exponential decay factor used in Equation~\ref{eq:recharge} here is the same as their Equation~4 with only different notation. \cite{trackeR:Skiba+Fulford+Clarke:2015} use $t$ to describe the length of the interval, $D_{CP} = CP - P_i$ for the difference between critical power and power output, and $W'_{exp}$ for the amount of $W'$ previously expended. For $P_i < CP$, as is required for replenishment, $-D_{CP}$ and $P_i - CP$ are negative and thus the exponential factor is smaller than 1, leading to an exponential decay as described. %% link to 2012 paper and their equation \cite{trackeR:Skiba+Chidnok+Vanhatalo:2012} also assume an exponential decay of previously expended $W'$ to describe replenishing $W'$, albeit with a different decay factor. Instead of $(P_i - CP) / W'_0$, they use $1/\tau_{W'}$. The relationship between the time constant of replenishing $\tau_{W'}$ and the difference between critical power and recovery power $\bar{P}$ is estimated based on experimental data as % \begin{equation*} %\label{eq:tau} \tau_{W'} = 546 \exp \left(-0.01 (CP - \bar{P}) \right) + 316 \end{equation*} % with recovery power $\bar{P}$ estimated by the mean of all power outputs below CP. Using Equation~\ref{eq:recharge}, i.e., the formulation of \cite{trackeR:Skiba+Fulford+Clarke:2015}, the change in $W'$ over the corresponding interval $[t_{i-1}, t_i)$ can be described through % \begin{align} W'(t_i) - W'(t_{i-1}) %% &= W'_0 - \left( W'_0 - W'(t_{i-1}) \right) \exp \left( %% \frac{P_i - CP}{W'_0} (t_i - t_{i-1}) \right) - W'(t_{i-1}) \nonumber \\ &= (W'_0 - W'(t_{i-1})) \left( 1 - \exp \left( \frac{P_i - CP}{W'_0} \Delta_i \right) \right) \, . \label{eq:recharge:interval} \end{align} % \subsubsection{Work capacity at time $t_j$} Equation~\ref{eq:discharge:interval} describes the depletion of $W'$ (when $P_i > CP$) and Equation~\ref{eq:recharge:interval} describes replenishment of $W'$ (when $P_i \le CP$) over an interval $[t_{i-1}, t_i)$. These two aspects can be combined to describe the change over the interval as % \begin{align} W'(t_i) - W'(t_{i-1}) = {} & -(P_i - CP) \Delta_i I(P_i > CP) \, + \nonumber \\ & (W'_0 - W'(t_{i-1})) \left( 1 - \exp \left( \frac{P_i - CP}{W'_0} \Delta_i \right) \right) (1 - I(P_i > CP)) \, . \nonumber \end{align} % The amount of $W'$ left at time point $t_j$, $j \in \{ 1, \ldots, n \}$, can thus be described through the initial amount $W'_0$ and the changes happening in the $j$ intervals of constant power previous to $t_j$: % \begin{align} W'(t_j) = {} & W'_0 + \sum_{i=1}^{j}{ ( W'(t_i) - W'(t_{i-1}) ) } \nonumber \\ = {} & W'_0 - \sum_{i=1}^{j}{(P_i - CP) \Delta_i I(P_i > CP)} \, + \nonumber \\ & \sum_{i=1}^{j}{ (W'_0 - W'(t_{i-1})) \left( 1 - \exp \left( \frac{P_i - CP}{W'_0} \Delta_i \right) \right) (1 - I(P_i > CP)) } \, . \label{eq:Wbalance} \end{align} % \emph{$W'$~expended} at time $t_j$ is then $W'_0 - W'(t_j)$. Function \fct{Wprime} can be used to calculate \emph{$W'$~expended} by setting argument \code{quantity} to \code{"expended"}. If \code{quantity} is set to \code{"balance"}, \fct{Wprime} calculates the current state $W'(t)$ (Equation~\ref{eq:Wbalance}). \fct{Wprime} contains implementations for \cite{trackeR:Skiba+Chidnok+Vanhatalo:2012} and \cite{trackeR:Skiba+Fulford+Clarke:2015}, which can be selected via the \code{version} argument. For example, session~11 of the example data is an interval training with a warm-up and cool-down phase. Assuming a critical speed of 4~meters per second, the following code chunk produces Figure~\ref{fig:WprimePlots}, which shows \emph{$W'$~expended}, based on the specification of \cite{trackeR:Skiba+Chidnok+Vanhatalo:2012}, along with the corresponding speed profile. % <>= wexp <- Wprime(runs, session = 11, quantity = "expended", cp = 4, version = "2012") plot(wexp, scaled = TRUE) @ % During the warm-up phase speed rarely exceeds 4 meters per second and \emph{$W'$~expended} remains low. Over the course of the interval training, \emph{$W'$~expended} rises during the high-intensity phases and drops during the recovery phases. In the last part of the session, speeds are mostly below 4 meters per second and \emph{$W'$~expended} drops again. \setkeys{Gin}{width=\textwidth} \begin{figure} \centering % <>= wexp <- Wprime(runs, session = 11, quantity = "expended", cp = 4, version = "2012") plot(wexp, scaled = TRUE) @ % \caption{$W'$ expended in session~11.} \label{fig:WprimePlots} \end{figure} \subsection{Distribution and concentration profiles}\label{subsec:profiles} \cite{trackeR:Kosmidis+Passfield:2015} introduce the concept of distribution profiles for which the \pkg{trackeR} package provides an implementation. These profiles are motivated by the need to compare sessions %% in terms of quantities such as heart rate and speed and use information on such variables as heart rate or speed during a session for further modelling. For a session lasting $t_n$ seconds, the distribution profile is defined as the curve $\{ v, \Pi(v) | v \geq 0\}$ where % \begin{equation*} %%\label{eq:distributionProfile} \Pi(v) = \int_{0}^{t_n}{I(v(t) > v) dt} \, . \end{equation*} % The function $\Pi(v)$ is monotone decreasing and describes the time spent exercising above a threshold $v$ for a variable $V$ under consideration (e.g., heart rate or speed). On the basis of observations $v_0, \ldots, v_n$ for $V$, at respective time points $t_0, \ldots, t_n$, the observed version of $\Pi(v)$ can be calculated as % \begin{equation*} %%\label{eq:distributionProfile:observed} P(v) = \sum_{i = 1}^{n}{(t_{i} - t_{i-1}) I(v_{i} > v)} \, . \end{equation*} % This can subsequently be smoothed respecting the positivity and monotonicity of $\Pi(v)$, e.g., via a shape constraint additive model with Poisson responses \citep{trackeR:Pya+Wood:2015}. The concentration profile is defined in \cite{trackeR:Kosmidis+Passfield:2015} as the negative derivative of a distribution profile and is suitable for revealing concentrations of time around certain values of the variable under consideration. Distribution profiles can be calculated using the \fct{distributionProfile} function which returns an object of class \class{distrProfile}. Concentration profiles can be derived from distribution profiles using \fct{concentrationProfile}, which returns an object of class \class{conProfile}. Table~\ref{tab:pkg:functions:2} includes an overview of constructor functions and available methods for distribution and concentration profiles. By default, distribution profiles are calculated for speed and heart rate on grids inferred from the data. % covering the ranges of $[0, 12.5]$ meters per second and $[0, 250]$ beats % per minute, respectively. The following code chunk illustrates the use of \fct{distributionProfile} and shows how users can specify the variables for which to calculate profiles and the respective grids. % <>= dProfile <- distributionProfile(runs, session = 1:4, what = c("speed", "heart_rate"), grid = list(speed = seq(0, 12.5, by = 0.05), heart_rate = seq(0, 250))) plot(dProfile, multiple = TRUE) @ % \setkeys{Gin}{width=\textwidth} \begin{figure}[t] \centering % <>= dProfile <- distributionProfile(runs, session = 1:4, what = c("speed", "heart_rate"), grid = list(speed = seq(0, 12.5, by = 0.05), heart_rate = seq(0, 250))) plot(dProfile, smooth = FALSE, multiple = TRUE) @ % \caption{Distribution profiles for sessions~1--4.} \label{fig:dprofile:smooth} \end{figure} The \code{multiple} argument of the \fct{plot} method determines whether to plot the profiles in separate panels (\code{FALSE}) or overlay them in a common panel (\code{TRUE}), as in Figure~\ref{fig:dprofile:smooth}. The different session lengths are clearly visible in the height of the curves at 0. Amongst the distribution profiles for speed, the descent of the profile for session~3 is slower than for the other sessions. This difference is most apparent in the concentration profiles, which are shown in Figure~\ref{fig:cprofile:smooth} and are produced by the following code chunk. % <>= cProfile <- concentrationProfile(dProfile, what = "speed") plot(cProfile, multiple = TRUE, smooth = TRUE) @ % The profile for session~3 has a mode at around 3.5~meters per second and another one at 5~meters per second, showing that this session involved training at a combination of low and high speeds. \setkeys{Gin}{width=0.8\textwidth} \begin{figure}[t] \centering % <>= cProfile <- concentrationProfile(dProfile, what = "speed") plot(cProfile, multiple = TRUE, smooth = TRUE) ## cProfileS <- concentrationProfile(dProfileS) ## plot(cProfileS, what = "speed", smooth = FALSE, multiple = TRUE) @ % \caption{Concentration profiles for sessions~1--4.} \label{fig:cprofile:smooth} \end{figure} \section{Handling units of measurement}\label{sec:units} Data objects of class \class{trackeRdata} and all objects derived from these (\class{trackeRdataSummary}, \class{trackeRdataZones}, \class{trackeRWprime}, %\linebreak \class{distrProfile}, and \class{conProfile}) carry an attribute with the relevant units of measurement. The \fct{getUnits} method returns the units of measurement for each variable and the \fct{changeUnits} method can be used to change one or more variables from one set of units to another. The following code chunk displays the current units of \code{run} for running, changes the unit for speed for running to miles per hour, and displays the changed units. % <>= subset(getUnits(runs), sport == "running") runTr2 <- changeUnits(run, variable = "speed", unit = "mi_per_h", sport = "running") subset(getUnits(runTr2), sport == "running") @ % Table~\ref{tab:units} shows the variables and the corresponding units that are currently supported in \pkg{trackeR}. \begin{table}[t] \centering \begin{tabular}{l p{12.5cm}} \hline Measurement & Unit(s) \\ \hline %% initial measurements/variables in trackeRdata objects latitude & degrees (\code{degree}, default) \\ longitude & degrees (\code{degree}, default) \\ altitude & meters~(\code{m}, default), kilometres~(\code{km}), miles~(\code{mi}), feet~(\code{ft}) \\ distance & meters~(\code{m}, default), kilometres~(\code{km}), miles~(\code{mi}), feet~(\code{ft}) \\ speed & meters per second~(\code{m_per_s}, default), kilometres per hour~(\code{km_per_h}), feet per minute~(\code{ft_per_min}), feet per second~(\code{ft_per_s}), miles per hour~(\code{mi_per_h}) \\ cadence\_running & steps per minute~(\code{steps_per_min}, default) \\ cadence\_cycling & revolutions per minute~(\code{rev_per_min}, default) \\ power & Watts~(\code{W}, default), kilowatts~(\code{kW}) \\ heart rate & beats per minute~(\code{bpm}, default) \\ %% quantities derived for session summaries pace & minutes per kilometre (\code{min_per_km}, default), minutes per mile~(\code{min_per_mi}), seconds per meter~(\code{s_per_m}) \\ duration & seconds~(\code{s}), minutes~(\code{min}), hours~(\code{h}) -- default is the largest possible unit for which the duration is larger than 1 \\ temperature & degrees Celcius~(\code{C}, default), degrees Fahrenheit~(\code{F}) \\ \hline \end{tabular} \caption{Supported units of measurement.} \label{tab:units} \end{table} If objects with different units are \fct{c}ombined in one object, the units of the first session are applied to all other sessions. Furthermore, the \fct{changeUnits} method uses name matching to figure out which conversion needs to be done. This allows the user to easily add support for converting from \code{unitOld} to \code{unitNew} by authoring a function named \code{unitOld2unitNew}. If we wish to report the speed summaries for session~1 in \code{runSummary} in feet per hour (not currently supported) instead of meters per second, we need to simply provide the appropriately named conversion function as illustrated below. Note that the conversion applies to all speed summaries, i.e., to ``average speed'' and ``average speed moving''. % <>= m_per_s2ft_per_h <- function(x) x * 3937/1200 * 3600 changeUnits(runSummary, variable = "speed", unit = "ft_per_h") @ % \section{Thresholding and smoothing}\label{sec:smoothing} There are instances where the data include artefacts due to inaccuracies in the GPS measurements. These can be handled with the \fct{threshold} method for objects of class \class{trackeRdata}, which replaces values outside the specified thresholds with \code{NA}. The variables and the (lower and upper) thresholds which should be applied for each variable can be specified through the arguments \code{variable}, \code{lower}, and \code{upper}, respectively. An example is given in \code{?threshold}. The default thresholds are listed in Table~\ref{tab:defaultThresholds} and, if necessary, are converted to the units of measurement used for the \class{trackeRdata} object. \begin{table}[t] \centering \begin{tabular}{llrrccc} \hline Variable & Unit & Lower threshold & Upper threshold & R & C & S \\ \hline latitude & degrees & -90 & 90 & x & x & x\\ longitude & degrees & -180 & 180 & x & x & x \\ altitude & meter & -500 & 9000 & x & x & x \\ distance & meter & 0 & $\infty$ & x & x & x \\ heart rate & beats per minute & 0 & 250 & x & x & x \\ speed & meters per second & 0 & $\infty$ & x & x & x \\ cadence\_running & steps per minute & 0 & $\infty$ & x & & \\ cadence\_cycling & revolutions per minute & 0 & $\infty$ & x & x & x\\ power & Watts & 0 & $\infty$ & & x & \\ pace & minutes per kilometre & 0 & $\infty$ & x & x & x \\ duration & seconds & 0 & $\infty$ & x & x & x \\ temperature & degrees Celsius & -20 & 60 & x & x & x\\ \hline \end{tabular} \caption{Default thresholds for running, cycling and swimming data. R stands for running, C stands for cycling and S for swimming, and an x indicates that the corresponding unit applies to that sport.} \label{tab:defaultThresholds} \end{table} The other option for data handling is the \fct{smoother} method for \class{trackeRdata} objects. This applies a summarising function, such as the mean or median, over a rolling window. Both operations \fct{threshold} and \fct{smoother} are used in the \fct{plot} method for \class{trackeRdata} objects. The default settings for \fct{plot} are to apply the thresholds specified in Table~\ref{tab:defaultThresholds} but not to smooth the data. The top left panel in Figure~\ref{fig:thresholdPlots} gives an example where no thresholds are applied and the top right panel uses default settings. The spike to over 20~meters per second in the top left panel is clearly an error in the data; the current world record for 100 meters (by Usain Bolt, August 16, 2009) is 9.58 seconds which translates to an average speed of 10.44 meters per second. The bottom panels show the effect of first applying the default thresholds and then smoothing the data through a rolling median with a window width of 20 observations, either done within the \fct{plot} method (bottom left) or explicitly via the \fct{threshold} and \fct{smoother} methods (bottom right). The following code chunk produces the four plots in Figure~\ref{fig:thresholdPlots}. % <>= plot(runs, session = 4, what = "speed", threshold = FALSE) plot(runs, session = 4, what = "speed") plot(runs, session = 4, what = "speed", smooth = TRUE, fun = "median", width = 20) run4 <- threshold(runs[4]) run4S <- smoother(run4, what = "speed", fun = "median", width = 20) plot(run4S, what = "speed", smooth = FALSE) @ % \setkeys{Gin}{width=\textwidth} \begin{figure}[t] \centering \begin{subfigure}[b]{0.45\textwidth} % <>= plot(runs, session = 4, what = "speed", threshold = FALSE) @ % \end{subfigure} %~ \begin{subfigure}[b]{0.45\textwidth} % <>= plot(runs, session = 4, what = "speed") + ggplot2::expand_limits(y = c(0, 21)) @ % \end{subfigure} %~ \begin{subfigure}[b]{0.45\textwidth} % <>= plot(runs, session = 4, what = "speed", smooth = TRUE, fun = "median", width = 20, cores = 2) + ggplot2::expand_limits(y = c(0, 12.5)) @ % \end{subfigure} %~ \begin{subfigure}[b]{0.45\textwidth} % <>= run4 <- threshold(runs[4]) run4S <- smoother(run4, what = "speed", fun = "median", width = 20, cores = 2) plot(run4S, what = "speed", smooth = FALSE) + ggplot2::expand_limits(y = c(0, 12.5)) @ % \end{subfigure} \caption{Speed profile of session~4 without thresholding~(top left), with the default settings~(top right), and with default thresholds as well as smoothing through a rolling median over a window of 20 observations done within the plot function~(bottom left) and separately~(bottom right).} \label{fig:thresholdPlots} \end{figure} The method \fct{smoother} is also available for distribution and concentration profiles. Smoothing a distribution profile requires a smoothing technique which respects the positivity and monotonicity of the distribution profile. This can be achieved by fitting a shape constrained additive model with Poisson responses as implemented in the \pkg{scam} package \citep{trackeR:pkg:scam}. % When smoothing concentration profiles, the raw profiles are transformed to distribution profiles which are subsequently smoothed preserving the positivity and monotonicity. The smooth concentration profiles are then derived from the smoothed distribution profiles. % % The \fct{plot} methods for \class{distrProfile} and \class{conProfile} smooth % the profiles prior to plotting by default. If smooth concentration profiles are all that is required, these can also be computed by using the \fct{concentrationProfile} method direction on the \class{trackeRdata} object, which will then use an appropriately scaled kernel density estimator on the values of the variables in \code{what}. This is a more computationally efficient operation, that computing the distribution profiles, smoothing them, and then taking finite differences of the smoothed distribution profiles. The following code chunk illustrates this and plots the concentration profiles using a ridgeline plot \citep{trackeR:pkg:ggridges}. The resulting plot is shown in Figure~\ref{fig:ridges}. <>= cProfile1 <- concentrationProfile(runs, what = "speed", limits = list(speed = c(0, 12.5))) ridges(cProfile1) @ \setkeys{Gin}{width=0.8\textwidth} \begin{figure}[t] \centering <>= cProfile1 <- concentrationProfile(runs, what = "speed", limits = list(speed = c(0, 12.5))) ridges(cProfile1) @ \caption{Ridgeline plot of concentration profiles.} \label{fig:ridges} \end{figure} % \clearpage \section{Case study}\label{sec:casestudy} <>= library("trackeR") data("runs", package = "trackeR") runsSummary <- summary(runs) @ The example data set included in the package contains \Sexpr{nsessions(runs)}~sessions of a single male runner in June 2013. A visualisation of scalar summaries for the sessions can be found in Figure~\ref{fig:summaryPlot}. The distance covered in those sessions ranges from \Sexpr{round(min(runsSummary$distance) / 1000, 2)} km to \Sexpr{round(max(runsSummary$distance) / 1000, 2)} km, and most sessions were spent moving almost the entire time. The code chunk below loads the data, applies thresholds, and calculates the smoothed distribution profiles for the \Sexpr{nsessions(runs)}~sessions. The corresponding concentration profiles are shown in Figure~\ref{fig:app:cpsmooth}. % <>= library("trackeR") data("runs", package = "trackeR") runsT <- threshold(runs) dpRuns <- distributionProfile(runsT, what = "speed") dpRunsS <- smoother(dpRuns) cpRuns <- concentrationProfile(dpRunsS) plot(cpRuns, multiple = TRUE, smooth = FALSE) @ % \setkeys{Gin}{width=\textwidth} \begin{figure}[t] \centering % <>= library("trackeR") data("runs", package = "trackeR") runsT <- threshold(runs) dpRuns <- distributionProfile(runsT, what = "speed") dpRunsS <- smoother(dpRuns) cpRuns <- concentrationProfile(dpRunsS) plot(cpRuns, multiple = TRUE, smooth = FALSE) #+ theme(legend.position = "none") @ % \caption{Smoothed speed concentration profiles for all \Sexpr{nsessions(runs)} sessions.} \label{fig:app:cpsmooth} \end{figure} \pagebreak The majority of the profiles for speed concentrate around 4~meters per second. However, the curves differ in their shape (unimodal or multimodal), height, and location (revealing concentrations at higher or lower speeds). Functional PCA \citep[e.g.,][]{trackeR:Ramsay+Silverman:2005} can be used to explain those differences ensuring that the profiles are treated directly as functions. \pkg{trackeR} contains a convenience function \fct{funPCA} which converts concentration/distribution profiles to the required functional data format and performs a functional PCA. \pkg{trackeR} can also be viewed as a stepping stone to further analysis of tracking data with other \proglang{R}~packages. For example, it contains a conversion function, \fct{profile2fd}, that transforms concentration and distribution profiles to class \class{fd} so that users have direct access to the facilities of the \pkg{fda} package \citep{trackeR:pkg:fda} for functional data analysis. The following code chunk shows the conversion to the required functional data format and the fitting of a functional PCA in separate steps. The PCA has four components and the share of variance is displayed in the last step. % %% Alternatively: sppca <- funPCA(cpRuns, what = "speed", nharm = 4) <>= library("fda") cpFd <- profile2fd(cpRuns, what = "speed") sppca <- pca.fd(cpFd, nharm = 4) varprop <- round(sppca$varprop * 100); names(varprop) <- 1:4 varprop @ % \setkeys{Gin}{width=0.8\textwidth} \begin{figure}[t] \centering % <>= ## refit fPCA so that trackeR's plot method is used sppca <- funPCA(cpRuns, what = "speed", nharm = 4) pp <- FALSE ## dotted = -, dashed = + plot(sppca, harm = 1:2, pointplot = pp) @ % \caption{Harmonics 1--2 for the speed concentration profiles. Mean function~(solid line) with suitable multiples of the harmonic added~(dashed line) and subtracted~(dotted line).} \label{fig:app:harmonics:speed} \end{figure} The first two harmonics capture \Sexpr{round(cumsum(varprop)[2])}\% of the variation between curves. Since further harmonics capture considerably less variation, only the first two are chosen for further inspection. Figure~\ref{fig:app:harmonics:speed} shows the mean function (solid line) and the variation captured in the two harmonics (between the dashed and dotted lines). %(between the $+$ and $-$ signs). The first harmonic (top panel) illustrates that the most important characteristic of the concentration profiles is the relative value, which is closely related to the overall session duration. The left panel of Figure~\ref{fig:app:score:speed} shows the score on the first harmonic versus ``duration moving'' which is calculated as part of the scalar session summaries. The second harmonic in the bottom panel of Figure~\ref{fig:app:harmonics:speed} shows variation along the speed thresholds in the centre of the curve. This variation can be explained well by the scalar measure ``average speed moving'' as shown in the right panel of Figure~\ref{fig:app:score:speed}. The concentration profiles and a functional PCA thus indicate that the two scalar summaries ``duration moving'' and ``average speed moving'' provide a good summary of the speed information in the sessions and can be used, for example, in order to incorporate speed as explanatory information in regression analyses. \setkeys{Gin}{width=\textwidth} \begin{figure}[t] \centering \begin{subfigure}[b]{0.45\textwidth} % <>= ## plot scores vs summary statistics scoresSP <- data.frame(sppca$scores) names(scoresSP) <- paste0("speed_pc", 1:4) d <- cbind(runsSummary, scoresSP) library("ggplot2") ## pc1 ~ session duration (moving) d$durationMoving <- as.numeric(d$durationMoving) ggplot(d) + geom_point(aes(x = durationMoving, y = speed_pc1)) + theme_bw() + labs(x = "duration moving [min]", y = "PC1") @ % \end{subfigure} % ~ \begin{subfigure}[b]{0.45\textwidth} % <>= ## pc2 ~ avg speed (moving) ggplot(d) + geom_point(aes(x = avgSpeedMoving, y = speed_pc2)) + theme_bw() + labs(x = "average speed moving [m/s]", y = "PC2") @ % \end{subfigure} \caption{PC1 score vs.\ ``duration moving'' (left) and PC2 score vs.\ ``average speed moving''~(right).} \label{fig:app:score:speed} \end{figure} % \section{Concluding remarks} \label{sec:outro} % The \pkg{trackeR} package provides classes and methods for importing and % handling the irregularly sampled spatio-temporal data that arise from % GPS-enabled tracking devices in sports. Currently it supports TCX and db3 % formats, but the package structure allows the easy inclusion of other % formats. After careful processing, the data are stored in session-based, % unit-aware, and operation-aware objects of class \class{trackeRdata}. Associated % methods handle conversion between units of measurement, calculation of relevant % summaries and the visualisation of tracking data. Time in zones, work capacity, % and distribution and concentration profiles can also be readily calculated and % used for further statistical analyses. An example of such analysis is presented % in Section~\ref{sec:casestudy}, where functional principal components analysis % is used to characterise the apparent variability between speed concentration % profiles. % Infrastructure for irregularly sampled spatio-temporal data in general is also % provided in the \pkg{trajectories} package \citep{trackeR:pkg:trajectories}, % which is developed around the \class{STIDF} class of the \pkg{spacetime} package % \citep{trackeR:Pebesma:2012}. In order to provide users with access to an as % wide range of data-analytic methods as is possible, we aim to provide a sensible % coercion function from \class{trackeRdata} to \class{STIDF}. One of the % challenges we are facing is that the \class{STIDF} class does not % accommodate missing values in positional or temporal information, which is % commonly the case in data from GPS-enabled tracking devices (e.g., sequences of % missing values in the positional data because the GPS signal is temporarily % lost). Other packages that offer tools for spatio-temporal data include % \pkg{adehabtitatLT} \citep{trackeR:Calenge:2006}, \pkg{trip} % \citep{trackeR:pkg:trip} and \pkg{move} \citep{trackeR:pkg:move}. The main focus % of those packages is on animal tracking (e.g., estimation of habitat choices) % and they are not directly suitable for tracking the various aspects of athlete activity. % Areas for further development include the extension of the reading capabilities % to more file formats and the implementation of more analytic tools, such as % record power profiles \citep{trackeR:Pinot+Grappe:2011}. The case study in % Section~\ref{sec:casestudy} draws some links to functional data analysis which % is another area of further exploration for analytic tools for the package. %\newpage \clearpage \section*{Acknowledgements} We are thankful to Victoria Downie, Andy Hudson, Louis Passfield, Ben Rosenblatt, and Achim Zeileis for helpful feedback and discussions as well as providing the data that are used for the illustrations and examples in the package. \pagebreak \clearpage \bibliography{trackeR} %%check journal and publisher names according to \url{http://www.jstatsoft.org/style} %% Journals: %% The American Statistician (not: American Statistician) %% The Annals of Statistics (not: Annals of Statistics) %% Journal of the Royal Statistical Society B (not: Journal of the Royal Statistical Society, Series B) %% Publishers: %% Springer-Verlag (not: Springer) %% John Wiley & Sons (not: Wiley, John Wiley & Sons Inc.) %\newpage \begin{appendix} \section[Replenishment of W']{Replenishment of $W'$} \label{sec:appendix} Assuming that power is constant, the solution of the differential equation describing the rate of replenishment in Equation~\ref{eq:recharge:rate} with respect to $W'(t)$ gives % \begin{equation} \label{eq:recharge:2} 1 - \frac{W'(t)}{W'_0} = \exp \left( \frac{P- CP}{W'_0} t + D / W'_0 \right) \, . \end{equation} % Using Equation~\ref{eq:recharge:2} over an interval $[t_{i-1}, t_i)$ of constant power gives % \begin{equation*} 1 - \frac{W'(t_i)}{W'_0} = \exp \left( \frac{P_i - CP}{W'_0} (t_i - t_{i-1}) \right) \left( 1 - \frac{W'(t_{i-1})}{W'_0} \right) \, . \end{equation*} % Hence, $W'(t_i)$ can be expressed in terms of $W'(t_{i-1})$ as % \begin{equation*} W'(t_i) = W'_0 - \left( W'_0 - W'(t_{i-1}) \right) \exp \left( \frac{P_i - CP}{W'_0} (t_i - t_{i-1}) \right) \, . \end{equation*} % %% , via the substitution rule for integrals in the %% step from Equation~\ref{eq:recharge:substitution1} %% to~\ref{eq:recharge:substitution2}, gives the following %% % %% \begin{align} %% \int{ \frac{d}{dt} W'(t) \frac{1}{1 - W'(t)/W'_0} } \, dt &= \int{ (CP %% - P)} \, dt \label{eq:recharge:substitution1} \\ %% \int{ \frac{1}{1 - W'(t)/W'_0} } \, d W'(t) & = \int{(CP - P)} \, dt \label{eq:recharge:substitution2}\\ %% \log \left( 1 - \frac{W'(t)}{W'_0} \right) (-W'_0) &= (CP- P) %% t + D \nonumber \\ %% 1 - \frac{W'(t)}{W'_0} &= \exp \left( \frac{P- CP}{W'_0} t + c \right) \label{eq:recharge:2} %% \end{align} %% % %% with $c = D / W'_0$. %% Note that power is again assumed to be constant, as it is in the case of %% depletion of $W'$. Applying this to an interval $[t_{i-1}, t_i)$ and setting %% Equation~\ref{eq:recharge:2} for time points $t_{i-1}$ and $t_i$ in relation to %% each other allows expressing $W'(t_i)$ in terms of $W'(t_{i-1})$: %% % %% \begin{align*} %% \frac{1 - \frac{W'(t_i)}{W'_0}}{1 - \frac{W'(t_{i-1})}{W'_0}} &= \frac{\exp %% \left( \frac{P_i - CP}{W'_0} t_i + c \right) }{\exp \left( \frac{P_i - %% CP}{W'_0} t_{i-1} + c \right) } \\ %% 1 - \frac{W'(t_i)}{W'_0} &= \exp \left( \frac{P_i - CP}{W'_0} (t_i - %% t_{i-1}) \right) \left( 1 - \frac{W'(t_{i-1})}{W'_0} \right) \\ %% W'_0 - W'(t_i) &= \exp \left( \frac{P_i - CP}{W'_0} (t_i - %% t_{i-1}) \right) \left( W'_0 - W'(t_{i-1}) \right) \\ %% W'(t_i) &= W'_0 - \left( W'_0 - W'(t_{i-1}) \right) \exp \left( \frac{P_i - %% CP}{W'_0} (t_i - t_{i-1}) \right) \, . %% \end{align*} %% % \end{appendix} \end{document}