Using Problem 12.2.1 Exercise 2 as a guide, use the ideas from Chapter 13 to answer the questions for table2.

library(tidyverse)

table2
  1. Compute the rate and include it in a final dataframe with the years as columns. Make a clustered bar graph.

  2. Now make a clustered bar graph. Question, which table is the one to use, table2_new or table2_new_spread?

LS0tCnRpdGxlOiAiUHJhY3RpY2UgZm9yIHRoZSBwcmFjdGljZSBRdWl6IgpvdXRwdXQ6CiAgd29yZF9kb2N1bWVudDogZGVmYXVsdAogIHBkZl9kb2N1bWVudDogZGVmYXVsdAogIGh0bWxfbm90ZWJvb2s6IGRlZmF1bHQKLS0tCgpVc2luZyBQcm9ibGVtIDEyLjIuMSBFeGVyY2lzZSAyIGFzIGEgZ3VpZGUsIHVzZSB0aGUgaWRlYXMgZnJvbSBDaGFwdGVyIDEzIHRvIGFuc3dlciB0aGUgcXVlc3Rpb25zIGZvciAqdGFibGUyKi4KCmBgYHtyIGV2YWw9RkFMU0V9CmxpYnJhcnkodGlkeXZlcnNlKQoKdGFibGUyCmBgYAoKMS4gQ29tcHV0ZSB0aGUgcmF0ZSBhbmQgaW5jbHVkZSBpdCBpbiBhIGZpbmFsIGRhdGFmcmFtZSB3aXRoIHRoZSB5ZWFycyBhcyBjb2x1bW5zLiAgTWFrZSBhIGNsdXN0ZXJlZCBiYXIgZ3JhcGguCgoyLiBOb3cgbWFrZSBhIGNsdXN0ZXJlZCBiYXIgZ3JhcGguIFF1ZXN0aW9uLCB3aGljaCB0YWJsZSBpcyB0aGUgb25lIHRvIHVzZSwgdGFibGUyX25ldyBvciB0YWJsZTJfbmV3X3NwcmVhZD8KIAoKIA==