Skip to content

Commit

Permalink
Improve package description and remove useless parameter "labelPrecis…
Browse files Browse the repository at this point in the history
…ion"
  • Loading branch information
FrancoisGuillem committed Apr 19, 2017
1 parent be20950 commit abb2c40
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 19 deletions.
6 changes: 3 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ Authors@R: c(
person("RTE", role = "cph")
)
Maintainer: Francois Guillem <[email protected]>
Description: This package provides functions to add and modify small charts on
an interactive map created with package "leaflet". They can be used to
represent at same time multiple variables on a single map.
Description: Add and modify small charts on an interactive map created with
package 'leaflet'. These charts can be used to represent at same time multiple
variables on a single map.
License: GPL (>= 2) | file LICENSE
Depends: R (>= 2.10)
Imports: leaflet,
Expand Down
12 changes: 4 additions & 8 deletions R/add_minicharts.R
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@
#' @param showLabels Should values be displayed above chart elements.
#' @param labelStyle Character string containing CSS properties to apply to the
#' labels.
#' @param labelPrecision Integer indicating the number of signficant digits to
#' keep when displaying numerci values
#' @param labelText character vector containing the text content of the charts.
#' Used only if \code{data} contains only one column.
#' @param transitionTime duration of the transitions when a property of a chart
Expand All @@ -59,8 +57,7 @@
addMinicharts <- function(map, lng, lat, data = 1, maxValues = NULL, type = "auto",
fillColor = NULL, colorPalette = NULL,
width = 30, height = 30, opacity = 1, showLabels = FALSE,
labelStyle = NULL,
labelPrecision = 0, labelText = NULL,
labelStyle = NULL, labelText = NULL,
transitionTime = 750, popup = NULL, layerId = NULL) {

type <- match.arg(type, c("auto", "bar", "pie", "polar-area", "polar-radius"))
Expand Down Expand Up @@ -99,7 +96,7 @@ addMinicharts <- function(map, lng, lat, data = 1, maxValues = NULL, type = "aut
required = list(lng = lng, lat = lat),
optional = list(type = type, width = width, height = height,
opacity = opacity, labels = labels,
labelStyle = labelStyle, labelPrecision = labelPrecision,
labelStyle = labelStyle,
transitionTime = transitionTime,
popup = popup, layerId = layerId, fillColor = fillColor)
)
Expand All @@ -124,8 +121,7 @@ addMinicharts <- function(map, lng, lat, data = 1, maxValues = NULL, type = "aut
updateMinicharts <- function(map, layerId, data = NULL, maxValues = NULL, type = NULL,
fillColor = NULL, colorPalette = NULL,
width = NULL, height = NULL, opacity = NULL, showLabels = NULL,
labelStyle = NULL,
labelPrecision = NULL, labelText = NULL,
labelStyle = NULL, labelText = NULL,
transitionTime = NULL, popup = NULL) {

type <- match.arg(type, c("auto", "bar", "pie", "polar-area", "polar-radius"))
Expand Down Expand Up @@ -164,7 +160,7 @@ updateMinicharts <- function(map, layerId, data = NULL, maxValues = NULL, type =
required = list(layerId = layerId),
optional = list(type = type, width = width, height = height,
opacity = opacity, labels = labels,
labelStyle = labelStyle, labelPrecision = labelPrecision,
labelStyle = labelStyle,
labelText = labelText, transitionTime = transitionTime,
popup = popup, fillColor = fillColor)
)
Expand Down
11 changes: 3 additions & 8 deletions man/addMinicharts.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit abb2c40

Please sign in to comment.