Showing posts with label facets. Show all posts
Showing posts with label facets. Show all posts

Monday, June 4, 2012

Dotplot with facets

  • x contains variables riskgroup, aod (for age of death) and sex
ggplot(x,aes(x=riskgroup,y=aod,colour=riskgroup)) + 
  geom_dotplot() + 
  facet(~sex) +
  xlab("Risk Group") +
  ylab("Age of Death")