Learn R Programming

googleway (version 2.0.0)

update_circles: Update circles

Description

Updates specific colours and opacities of specified circles Designed to be used in a shiny application.

Usage

update_circles(map, data, id, radius = NULL, draggable = NULL,
  stroke_colour = NULL, stroke_weight = NULL, stroke_opacity = NULL,
  fill_colour = NULL, fill_opacity = NULL, layer_id = NULL)

Arguments

map

a googleway map object created from google_map()

data

data.frame containing the new values for the circles

id

string representing the column of data containing the id values for the circles. The id values must be present in the data supplied to add_circles in order for the polygons to be udpated

radius

either a string specifying the column of data containing the radius of each circle, OR a numeric value specifying the radius of all the circles (radius is expressed in metres)

draggable

string specifying the column of data defining if the circle is 'draggable' (either TRUE or FALSE)

stroke_colour

either a string specifying the column of data containing the stroke colour of each circle, or a valid hexadecimal numeric HTML style to be applied to all the circles

stroke_weight

either a string specifying the column of data containing the stroke weight of each circle, or a number indicating the width of pixels in the line to be applied to all the circles

stroke_opacity

either a string specifying the column of data containing the stroke opacity of each circle, or a value between 0 and 1 that will be applied to all the circles

fill_colour

either a string specifying the column of data containing the fill colour of each circle, or a valid hexadecimal numeric HTML style to be applied to all the cirlces

fill_opacity

either a string specifying the column of data containing the fill opacity of each circle, or a value between 0 and 1 that will be applied to all the circles

layer_id

single value specifying an id for the layer.