mutate function error

mutate function giving error message below
Error: Problem with mutate() column total.
:information_source: total = "adr"/adults.
x non-numeric argument to binary operator
Run rlang::last_error() to see where the error occurred.

RStudio Cloud

It is very hard to say what the problem is without seeing your data and more of your code. The problem may be fixed by removing the quotes from adr. Try

total = adr/adults

If that does not work, please post the output of

dput(head(DF))

where you replace DF with the name of the data frame you are using and also post the entire code of the mutate() call. Please put three back ticks before and after the code that you post.
```
Your code here
```

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.