Это то, что вы ищете?
tomatoes <- data.frame(V1 = c("yield,mulch","4547,bare","2512,bare",
"4840,bare", "6749,compost","7616,compost"))
Разделите V1
на две колонки через запятую:
tomatoes$yield <- str_extract(tomatoes$V1, "\\d+")
tomatoes$mulch <- str_extract(tomatoes$V1, "[A-z]+")
Нарисуйте свой график:
library(ggplot2)
ggplot(tomatoes[-1,], aes(x=yield))+ geom_dotplot()+facet_grid(~mulch)
![enter image description here](https://i.stack.imgur.com/UCldf.png)