| FitFile-accessors | R Documentation |
Methods for retrieving messages from FitFile-class objects.
listMessageTypes(fitFile)
## S4 method for signature 'FitFile'
listMessageTypes(fitFile)
getMessagesByType(fitFile, message_type)
## S4 method for signature 'FitFile,integer'
getMessagesByType(fitFile, message_type)
## S4 method for signature 'FitFile,character'
getMessagesByType(fitFile, message_type)
## S4 method for signature 'FitFile'
messages(fitFile)
file_id(fitFile)
## S4 method for signature 'FitFile'
file_id(fitFile)
records(fitFile)
## S4 method for signature 'FitFile'
records(fitFile)
laps(fitFile)
## S4 method for signature 'FitFile'
laps(fitFile)
events(fitFile)
## S4 method for signature 'FitFile'
events(fitFile)
hrv(fitFile)
## S4 method for signature 'FitFile'
hrv(fitFile)
monitoring(fitFile)
## S4 method for signature 'FitFile'
monitoring(fitFile)
fitFile |
A |
message_type |
Either an integer or character vector (length 1), specifying either a global message number or message type respectively. |
The FIT file specification allows for a large number of message types.
FITfileR provides accessor methods for some of the most common. These
include records() and laps().
If a predefined function doesn't exist for the message type you want to
extract, any message type can be retrieved with getMessagesByType.
The second argument can take either the global message number (as specified
in the FIT File definition) of message type you want, or the message name.
A list of names for the message types held in a FitFile-class
object can be retrieved with listMessageTypes.
The return type is dependant upon whether the FitFile-class
contains multiple message definitions for the same message type. It is not
uncommon for this to occur e.g. if a new sensor is added during an activity
the records field definition will change. If there is a single definition
for the message type a tibble will be returned, otherwise a list of
tibbles is returned. The length of this list reflects the number of
unique definitions for the message type within the file. It may be
straightforward to combine these tibbles e.g. via rbind, but
this is left to the user.
Either a tibble or a list of tibble. See details for more
information.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.