once you include a line of code for scale_y_break(), the command for margins stops working. below you can try commenting out the scale_y_break() line to reproduce this issue.
library(ggplot2)
library(ggbreak)
ggplot(mtcars, aes(x=as.factor(cyl), y=mpg)) +
geom_boxplot(fill="slateblue", alpha=0.2) +
xlab("cyl")+
theme(plot.margin = margin(t = 2, l = 3, r = 2, b = 2, "cm"))+
scale_y_break(c(1, 7))
thanks for this package, i love being able to use it to put in an axis break! wanted to report what seems like a bug that someone else had posted without a resolution on stack overflow: https://stackoverflow.com/questions/75871080/plot-margin-fails-after-scale-y-cut
once you include a line of code for scale_y_break(), the command for margins stops working. below you can try commenting out the scale_y_break() line to reproduce this issue.
thanks!