Aus_athletes: Australian athletes

Description Usage Format References Examples

Description

This dataset is equivalent to ais from the DAAG package.

Usage

1

Format

An object of class data.frame with 202 rows and 13 columns.

References

Telford, R.D. and Cunningham, R.B. 1991. Sex, sport and body-size dependency of hematology in highly trained athletes. Medicine and Science in Sports and Exercise 23: 788-794.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
library(dplyr)
library(ggplot2)
library(colorblindr)

male_Aus <- filter(Aus_athletes, sex=="m") %>%
  filter(sport %in% c("basketball", "field", "swimming", "track (400m)",
                      "track (sprint)", "water polo")) %>%
  mutate(sport = case_when(sport == "track (400m)" ~ "track",
                           sport == "track (sprint)" ~ "track",
                           TRUE ~ sport))

male_Aus$sport <- factor(male_Aus$sport,
  levels = c("field", "water polo", "basketball", "swimming", "track"))

ggplot(male_Aus, aes(x=height, y=pcBfat, color=sport, fill=sport, shape=sport)) +
  geom_point(size = 3) +
  scale_shape_manual(values = 21:25) +
  scale_color_OkabeIto(order=c(2, 1, 3, 4, 5), darken = 0.3) +
  scale_fill_OkabeIto(order=c(2, 1, 3, 4, 5), darken = 0.1, alpha = 0.5) +
  ylab("% bodyfat") +
  theme_minimal()

clauswilke/dviz.supp documentation built on Aug. 25, 2020, 2:12 a.m.