library(ggplot2)
library(dplyr)
# Top speed by species
ggplot(lizard_run, aes(x = top_speed, color = common_name, fill = common_name)) +
geom_density(alpha = 0.5)
# Top speed summary statistics by species
lizard_run %>%
group_by(common_name) %>%
summarise(
n = n(),
mean = mean(top_speed),
sd = sd(top_speed)
)
Run the code above in your browser using DataLab