How to create a legend with both color and shape
问题 I have created a 4*2 experiment design(4 treatments and 2 repeats of each treatment) and wanted to use 4 shapes and 2 colors symbols to classify the 4*2 experiments in ggplot2. I have two legends, one for shapes and the other one for two colors, and I want to combine the two legends into a single legend. I have searched the post(Combine legends for color and shape into a single legend), but still have no idea to solve the problem. Thank you in advance! My data: x y Treatment Repeat 75