0

So I have light treatment as a fixed variable on the x-axis and I would like to overlap feeding rate and median day of death on the y-axis. I would also be happy with something that looks like this [image]

Here is my data

enter image description here

ggplot(data = df_median, aes(x = Median_death, y = Feeding_rate,
                                   colour = factor(Light_treatment), group = factor(Light_treatment),
                                   fill = after_scale(color)))+
  beside = TRUE+
  labs(x = "Light treatment", 
       y = "Feeding rate",
       title = "Feeding rate across treatments",
       color = 'Group') +
  scale_color_manual(values = c("grey50", "red3", "blue2", "yellow2", "green3", "pink")) +
  theme_bw() 

This is what I have tried but it just ends up looking messy and not clear at all.

aynber
  • 22,380
  • 8
  • 50
  • 63
  • 5
    It's easier to help you if you include a simple [reproducible example](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example) with sample input and desired output that can be used to test and verify possible solutions. Please [do not post data in images](https://meta.stackoverflow.com/q/285551/2372064) – MrFlick Apr 11 '23 at 13:48

0 Answers0