Learn R Programming

plotGoogleMaps (version 2.0)

iconlabels: Create icon markers depending on attribute data.

Description

The function provide links to icon markers or icon labels ready to use for plotGoogleMaps.

Usage

iconlabels(attribute,
                     colPalette=NULL,
                     at=NULL,
                     height=10,
                     icon=FALSE,
                     scale=0.6
                     
  )

Arguments

Value

The function provide links to icon markers or icon labels ready to use for plotGoogleMaps.

See Also

plotGoogleMaps, ellipseGoogleMaps, bubbleGoogleMaps

Examples

Run this code
# Data preparation
data(meuse)
coordinates(meuse)<-~x+y
proj4string(meuse) <- CRS('+init=epsg:28992')

m<-plotGoogleMaps(meuse,zcol='zinc',filename='myMap_z1.htm')
# see results in your working directory

# zinc labels
ic=iconlabels(meuse$zinc, height=12)
m<-plotGoogleMaps(meuse,zcol='zinc',filename='myMap_z2.htm', iconMarker=ic)

# landuse labels and markers
ic=iconlabels(meuse$landuse, height=12, colPalette=rainbow(15) )
m<-plotGoogleMaps(meuse,zcol='landuse',colPalette=rainbow(15), filename='myMap_lu.htm', iconMarker=ic)

ic=iconlabels(meuse$landuse, height=12, colPalette='#9ECAE1', icon=TRUE)
m<-plotGoogleMaps(meuse,zcol='landuse',colPalette='#9ECAE1', filename='myMap_lu2.htm', iconMarker=ic)

Run the code above in your browser using DataLab