Creates a tmap-element that adds a manual legend.
tm_add_legend(type = c("fill", "symbol", "text", "line"), labels = NULL,
col = NULL, size = NULL, shape = NULL, lwd = NULL, lty = NULL,
text = NULL, alpha = NA, border.col = "black", border.lwd = 1,
border.alpha = NA, title = "", is.portrait = TRUE,
legend.format = list(), reverse = FALSE, z = NA)type of legend. One of "fill", "symbol", "text", or "line"
legend labels
legend colors
legend symbol sizes (if type=="symbol")
legend symbol shapes (if type=="symbol")
legend line widths (if type=="line")
legend line types (if type=="line")
legend texts (if type=="text")
legend fill transparancy
legend border col (if type is "fill" or "symbol")
legend border width (if type is "fill" or "symbol")
legend border alpha (if type is "fill" or "symbol")
legend title
is legend portrait (TRUE) or landscape (FALSE)?
options to format the legend, see tm_layout
are the legend items reversed (by default FALSE)?
legend stack position
tm_symbols for an example