You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have updated my R to version 3.5. There is too small margin for legend.text when using theme(legend.title=element_blank()), while it is normal without adding this line code.
require(ggplot2)
df<-reshape2::melt(outer(1:4, 1:4), varnames= c("X1", "X2"))
p1<- ggplot(df, aes(X1, X2)) + geom_tile(aes(fill=value))
p1+scale_fill_continuous(guide= guide_legend())
# there is normal spacing (margin) for legend.textp1+scale_fill_continuous(guide= guide_legend())+
theme(legend.title=element_blank())
# there is too small spacing (margin) for legend.text