Set option parameters for sb_get_event()
Usage
sb_get_event_option(
interactive_mode = TRUE,
include_user_data = TRUE,
cache = TRUE,
download_attachment = FALSE,
include_missing_user = FALSE,
guess_col_type = TRUE,
include_uuid = FALSE
)
Arguments
- interactive_mode
If TRUE, all messages are printed to the console. If FALSE, they are suppressed. The idea is that
interactive_mode
should be set to FALSE in automated environments to ensure logs aren't clogged up with progress messages.- include_user_data
If TRUE, information like the athlete's full name (i.e. about) is attached to the exported data frame. Setting this to FALSE can improve query performance since
sb_get_event()
doesn't need to make an extra API call to grab the user data.- cache
If TRUE, login token and user details are cached once per session. Similar to
include_user_data
, caching can have performance benefits when the user data set is large, such as on large Smartabase sites with thousands of users. To invalidate the cache, restart your R session.- download_attachment
If TRUE, will download any files that are included in the form via a file upload field.
- include_missing_user
If TRUE, includes users who have not recorded data in that form as rows of NA values.
- guess_col_type
If TRUE,
sb_get_event()
usesreadr::type_convert()
to guess the column types of the exported data frame. If FALSE, all columns will come through as character.- include_uuid
If TRUE, each athlete's user-defined UUID (universally unique identifier) is attached to the exported data frame. Note, this is different to user_id, which is automatically generated by Smartabase.
See also
sb_sync_event_option()
sb_get_user_option()
sb_get_profile_option()
sb_get_group_option()
Other export option helpers:
sb_get_group_option()
,
sb_get_profile_option()
,
sb_get_user_option()
,
sb_sync_event_option()
Examples
if (FALSE) { # \dontrun{
# Calling the function with no arguments returns all the defaults
sb_get_event_option()
# Specifying specific arguments will alter those arguments alone while still
# returning the other defaults
sb_get_event_option(guess_col_type = FALSE, interactive_mode = FALSE)
} # }