Raincloud plot - Histogram

Hi,

I would like to create a raincloud plot. I have successfully done it. But I would like to know if instead of the density curve, I can put a histogram (it's better for my dataset).
This is my code if it can be usefull

ATSC <- ggplot(data = data, aes(y = atsc, x = numlecteur, fill = numlecteur)) +
  geom_flat_violin(position = position_nudge(x = .2, y = 0), alpha = .5) +
  geom_point(aes(y = atsc, color = numlecteur), position = position_jitter(width = .15), size = .5, alpha = 0.8) +
  geom_point(data = sumld, aes(x = numlecteur, y = mean), position = position_nudge(x = 0.25), size = 2.5) +
  geom_errorbar(data = sumld, aes(ymin = lower, ymax = upper, y = mean), position = position_nudge(x = 0.25), width = 0) +
  guides(fill = FALSE) +
  guides(color = FALSE) +
  scale_color_brewer(palette = "Spectral") +
  scale_y_continuous(breaks=c(0,2,4,6,8,10), labels=c("0","2","4","6","8","10"))+
  scale_fill_brewer(palette = "Spectral") +
  coord_flip() +
  theme_bw() +
  expand_limits(y=c(0, 10))+
  xlab("Lecteur") + ylab("Age total sans check")+
  raincloud_theme

I think we can maybe put the "geom_histogram()" but it doesn't work

Thank you in advance for your help !

L.SIMONET

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.