Try to look at the link:

http://www.cookbook-r.com/Graphs/Legends_(ggplot2)/


Also consider:

help(theme)

legend.background    background of legend (element_rect; inherits from rect)
legend.margin   extra space added around legend (unit)
legend.key background underneath legend keys (element_rect; inherits from rect)
legend.key.size size of legend keys (unit; inherits from legend.key.size)
legend.key.height    key background height (unit; inherits from legend.key.size)
legend.key.width     key background width (unit; inherits from legend.key.size)
legend.text     legend item labels (element_text; inherits from text)
legend.text.align    alignment of legend labels (number from 0 (left) to 1 
(right))
legend.title    title of legend (element_text; inherits from title)
legend.title.align   alignment of legend title (number from 0 (left) to 1 
(right))
legend.position the position of legends ("none", "left", "right", "bottom", 
"top", or two-element numeric vector)
legend.direction     layout of items in legends ("horizontal" or "vertical")
legend.justification anchor point for positioning legend inside plot ("center" 
or two-element numeric vector)
legend.box arrangement of multiple legends ("horizontal" or "vertical")
legend.box.just justification of each legend within the overall bounding box, 
when there are multiple legends ("top", "bottom", "left", or "right")

--

GG

        [[alternative HTML version deleted]]

______________________________________________
[email protected] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to