Common tasks in R