Learn R Programming

injurytools (version 2.0.1)

calc_summary: Calculate summary statistics

Description

Calculate epidemiological summary statistics such as case (e.g. injury) incidence and case burden (see Bahr et al. 2018), including total number of cases, number of days lost due to this event, total time of exposure etc., by means of a (widely used) Poisson method, negative binomial, zero-inflated poisson or zero-inflated negative binomial, on a athlete and overall basis.

Usage

calc_summary(
  injd,
  by = NULL,
  overall = TRUE,
  method = c("poisson", "negbin", "zinfpois", "zinfnb"),
  conf_level = 0.95,
  scale = TRUE,
  quiet = FALSE,
  ...
)

Value

A data frame comprising of overall or athlete-wise epidemiological summary statistics, that it's made up of the following columns:

  • totalexpo: total exposure that the athlete has been under risk of suffering a sports-related health problem.

  • ncases: number of sports-related health problems suffered by the athlete or overall in the team/cohort over the given period specified by the injd data frame.

  • ndayslost: number of days lost by the athlete or overall in the team/cohort due to the sports-related health problem over the given period specified by the injd data frame.

  • mean_dayslost: average of number of days lost (i.e. ndayslost) athlete-wise or overall in the team/cohort.

  • median_dayslost: median of number of days lost (i.e. ndayslost) athlete-wise or overall in the team/cohort.

  • qt25_dayslost and qt75_dayslost: interquartile range of number of days lost (i.e. ndayslost) athlete-wise or overall in the team/cohort.

  • incidence: case incidence rate, number of cases per unit of exposure.

  • burden: case burden rate, number of days lost per unit of exposure.

  • incidence_sd and burden_sd: estimated standard deviation, by the specified method argument, of case incidence (incidence) and case burden (burden).

  • incidence_lower and burden_lower: lower bound of, for example, 95% confidence interval (if conf_level = 0.95) of case incidence (incidence) and case burden (burden).

  • incidence_upper and burden_upper: the same (as above item) applies but for the upper bound.

Apart from this column names, they may further include these other columns depending on the user's specifications to the function:

  • by: only if it is specified as an argument to function.

  • percent_ncases: percentage (%) of number of cases of that type relative to all types of cases (if by specified).

  • percent_dayslost: percentage (%) of number of days lost because of cases of that type relative to the total number of days lost because of all types of cases (if by specified).

Arguments

injd

injd S3 object (see prepare_all()).

by

Character specifying the name of the column according to which compute summary statistics. It should refer to a (categorical) variable that describes a grouping factor (e.g. "type of case or injury", "injury location", "sports club"). Optional, defaults to NULL.

overall

Logical, whether to calculate overall (for all the cohort) or athlete-wise summary statistic (i.e. number of cases per cohort of per athlete). Defaults to TRUE.

method

Method to estimate the incidence (burden) rate. One of "poisson", "negbin", "zinfpois" or "zinfnb"; that stand for Poisson method, negative binomial method, zero-inflated Poisson and zero-inflated negative binomial.

conf_level

Confidence level (defaults to 0.95).

scale

Logical, whether to transform the incidence and burden rates output according to the unit of exposure (defaults to TRUE).

quiet

Logical, whether or not to silence the warning messages (defaults to FALSE).

...

Other arguments passed on to calc_incidence function arguments.

References

Bahr R., Clarsen B., & Ekstrand J. (2018). Why we should focus on the burden of injuries and illnesses, not just their incidence. British Journal of Sports Medicine, 52(16), 1018–1021. tools:::Rd_expr_doi("10.1136/bjsports-2017-098160")

Waldén M., Mountjoy M., McCall A., Serner A., Massey A., Tol J. L., ... & Andersen T. E. (2023). Football-specific extension of the IOC consensus statement: methods for recording and reporting of epidemiological data on injury and illness in sport 2020. British journal of sports medicine.

Examples

Run this code
calc_summary(injd)
calc_summary(injd, overall = FALSE)
calc_summary(injd, by = "injury_type")
calc_summary(injd, by = "injury_type", overall = FALSE)

Run the code above in your browser using DataLab