I have something like the following Dataset:
1. Donation 2. Treatment 3. Category.
2€ TG2 Teenager
1€ TG1 Adult
2€ TG2 Adult
and so on
There are multiple participants. Every Participant is part of a special Treatmentgroup (TG) and is assigned to a category.
I would now like to plot two barplots like this:
- Donations of all TGs in one diagram
- Donations of all Categories in one diagram
I'm not sure how to do that. If i use barplot(table(Donation)), it gives me the barplot of the donations only. Can I somehow group this data in a barplot?
For example