Description Usage Arguments Details Examples
View source: R/createSession.R
Function to set up a user swim threshold
1 2 3 4 5 6 7 8 9 |
sports |
(list) One of the sports: bike, run, swim |
metrics |
(list) One of 'power', 'pace', 'HR' |
minTargetZs |
(list) Number of a minutes at a specified intensity for each sport/session |
targetZs |
(list) The session intensity for the minutes specified. Numeric for type = bike, character otherwise |
TSS |
(list) the known TSS for the session. If this is given (and is not NA (default)) it will be used to set the session TSS, even if intervals are given. |
userSettings |
(userSettings) an object of class userSettings |
description |
(character) Optional session description. If NULL, it will be set to the type |
Create a new training session
1 2 3 4 5 6 7 8 9 10 | ##set the run threshold to 4:30
myThreshold <- addThreshold(sport = 'run', metric = 'pace', value = '4:30')
##set the bike threshold to 250
myThreshold <- addThreshold(sport = 'bike', metric = 'power', value = 250, userSettings = myThreshold)
##create a brick session
newSession <- createSession(sports=list('run', 'bike'),
minTargetZ = list(c(20, 30), 60), targetZ = list(c('1:20', '1:40'), 250),
metric = list('pace', 'power'), userSettings = myThreshold, TSS = list(NA, NA),
description = 'making a test session')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.