0

Let's say I have a sample dataset that looks like this

df <- data.frame(cat = letters[1:5], val1 = sample(1:10, 5), val2 = sample(1:10, 5))

I want to plot a bar graph with cat in the x axis, and for each cat, compare the two values with separate bars close to each other.
What I want is something that looks like this enter image description here

0 Answers0