addIcon: Add Icons to a Map or RgoogleMap Plot

Description Usage Arguments Note Examples

View source: R/addIcon.R

Description

Adds an icon to map – an RgoogleMaps map object. The following icons are available:

You can use other .png files as icons by passing an absolute path as the icon argument.

Usage

1
addIcon(icon, longitude, latitude, map = NULL, expansion = 0.1, pos = 0)

Arguments

icon

object to be plotted

longitude

vector of longitudes

latitude

vector of latitudes

map

optional RgoogleMaps map object

expansion

icon expansion factor

pos

position of icon relative to location (0=center, 1=bottom, 2=left, 3=top,4=right)

Note

For RgoogleMaps, the expansion will be ~ 0.1 while for basic plots it may need to be much smaller, perhaps ~ 0.001.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 
library(PWFSLSmoke)

monitor_map(Camp_Fire)

addIcon(
  "orangeFlame",
  longitude = -121.437222,
  latitude = 39.810278,
  expansion = 0.003
)

## End(Not run)

PWFSLSmoke documentation built on Nov. 23, 2021, 5:06 p.m.