mf_legend_p: Plot a legend for a proportional symbols map

View source: R/mf_leg_p.R

mf_legend_pR Documentation

Plot a legend for a proportional symbols map

Description

Deprecated.

This function plots a legend for proportional symbols.

Usage

mf_legend_p(
  pos = "left",
  val,
  col = "tomato4",
  inches,
  symbol = "circle",
  border,
  lwd = 0.7,
  title = "Legend Title",
  title_cex = 0.8,
  val_cex = 0.6,
  val_rnd = 0,
  frame = FALSE,
  bg,
  fg,
  cex = 1,
  self_adjust = FALSE
)

Arguments

pos

position of the legend, one of "topleft", "top", "topright", "right", "bottomright", "bottom", "bottomleft", "left", "interactive" or a vector of two coordinates in map units (c(x, y)).

val

vector of values (at least min and max).

col

color of the symbols

inches

size of the biggest symbol (radius for circles, half width for squares) in inches

symbol

type of symbols, 'circle' or 'square'

border

color of the symbols borders

lwd

width of the symbols borders

title

title of the legend

title_cex

size of the legend title

val_cex

size of the values in the legend

val_rnd

number of decimal places of the values in the legend.

frame

whether to add a frame to the legend (TRUE) or not (FALSE)

bg

background of the legend

fg

foreground of the legend

cex

size of the legend; 2 means two times bigger

self_adjust

if TRUE values are self-adjusted to keep min, max and intermediate rounded values

Value

No return value, a legend is displayed.

Examples

## Not run: 
plot.new()
plot.window(xlim = c(0, 1), ylim = c(0, 1), asp = 1)
mf_legend_p(val = c(1, 20, 100), col = "red", inches = .3)

## End(Not run)

mapsf documentation built on May 29, 2024, 7:12 a.m.