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
Is it possible to do positional adjustments (top, bottom, left, right) in the guide in scale_*_* and guides in combination with the theme for the bottom-left position, etc.? Currently only adjusts to the bottom, but not to the right. legend.justification = 'left' or legend.justification.bottom = 'left' for both of the following does not work as expected:
The justification of legends are a property of the legend boxes, not individual guides. We cannot let guides determine, in a bottom-up fashion, what the properties of legend boxes are because it would result in contorted code. At best, we can document more clearly which theme elements are ignored in guide_*(theme).
That is roughly correct, except that the legend box is fit to the guides. You can visualise it using the theme(legend.box.background). Come to think of it, it probably wouldn't hurt to specify this in the documentation about legend.justification.
Happy New Year in advance!
The update in version 3.5 https://www.tidyverse.org/blog/2024/02/ggplot2-3-5-0-legends/#placement mentions the fine adjustment of the legend position, which can now be done in combination with
guides
andtheme
.It was the expected result and worked out well:
Is it possible to do positional adjustments (top, bottom, left, right) in the guide in
scale_*_*
andguides
in combination with thetheme
for the bottom-left position, etc.? Currently only adjusts to the bottom, but not to the right.legend.justification = 'left'
orlegend.justification.bottom = 'left'
for both of the following does not work as expected:The text was updated successfully, but these errors were encountered: