marks()
calculates marks for track and field combined events competitions.
marks(scores, gender, combined_event = NULL, seconds = FALSE)
scores | a numeric vector of track and field scores |
---|---|
gender | gender of athlete; either " |
combined_event | an optional character string indicating the
combined events competition. For
|
seconds | a logical; if |
A list of class "combined_events
" (or "combined_events_null
" if combined_event = NULL
) with
the following fields:
if called with non-NULL combined_event
, a data frame with
columns for the specified combined event containing the names of those events, mark
for the resulting marks based on the input scores, and score
based on the input
scores. The last row of the data frame gives the total score for the specified combined
events competition. If combined_event = NULL
, a data frame with columns event
,
mark
, and score
.
the vector of marks based on the input scores for the specified combined event.
If not all scores were supplied to marks()
, then there will be NA
values
for those events with missing scores. If combined_event = NULL
, the vector of marks.
the vector of scores for the specified combined event. If not all scores
were supplied to marks()
, then there will be NA
values for those events with
missing scores. If combined_event = NULL
, the vector of scores.
if called with non-NULL combined_event
, an integer representing the overall score
for the specified combined events competition
the matched call
marks()
performs the opposite action of scores()
:
you give it the scores you want to obtain, and it gives you the marks you
need to achieve those scores. For track events, marks()
returns the
slowest time needed to achieve the input score. Similarly, for jumping and
throwing events, marks()
returns the shortest distance necessary to
achieve the input score.
For some events, when a score is given to marks()
, the score returned may
be different from the one input because some scores are not actually
possible (due to rounding of track and field marks). When an impossible
score is given to marks()
, the function will return the closest higher
score that corresponds to a mark.
International Association of Athletics Federation (2001). IAAF Scoring Tables for Combined Events.
#> heptathlon mark score #> 1 60m 7.23 802 #> 2 LJ 6.95 802 #> 3 SP 15.16 800 #> 4 HJ 2 803 #> 5 60mH 8.76 800 #> 6 PV 4.64 802 #> 7 1000m 2:46.78 800 #> 8 TOTAL <NA> 5609# Women's pentathlon marks(scores = c(`60mH` = 981, HJ = 875, SP = 799, LJ = 956, `800m` = 1000), "female", "pentathlon")#> pentathlon mark score #> 1 60mH 8.66 982 #> 2 HJ 1.72 879 #> 3 SP 14.07 799 #> 4 LJ 6.34 956 #> 5 800m 2:07.63 1000 #> 6 TOTAL <NA> 4616# Men's events marks(scores = c(LJ = 790, LJ = 810, HJ = 850, HJ = 900, PV = 900, PV = 915), "male")#> event mark score #> 1 LJ 6.90 790 #> 2 LJ 6.99 811 #> 3 HJ 2.05 850 #> 4 HJ 2.11 906 #> 5 PV 4.97 901 #> 6 PV 5.02 917