Can you explain a bit more abut what you are doing? It appears than you have a data set called Cause_of_death but without a sample of it, I don't see what we can do.
Paste your code here between
```
```
This gives us a nicely formatted code.
A handy way to supply data is to use the dput() function. Do dput(mydata) where "mydata" is the name of your dataset. For really large datasets probably dput(head(mydata, 100)) will do. Paste the output between
```