legJust | R Documentation |
Add legend with right-justification, functionalising Uwe Ligges'
example in ?legend
. Really a way of adding text automatically in
the corner (which legend()
works out the positioning for).
legJust(
textVec,
pos = "topright",
textWidth = "slope=-*.**",
inset = 0,
logxy = FALSE
)
textVec |
text for the legend, one element for each row |
pos |
position of the legend (not tested for all positions) |
textWidth |
width to make the text |
inset |
inset distance |
logxy |
TRUE if axes are logarithmic |
Adds legend to exiting plot. Returns NULL.
Andrew Edwards
## Not run:
plot(10:1)
legJust(c("Method", paste("value=", mean(1:10), sep=""), "x=7.0"))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.