Produce Charts that you See on the Fingertips Website

Use Fingertips charts to recreate the visualisations that are displayed on the Fingertips website (<>).

BuildStatus CoverageStatus

CRAN StatusBadge CRAN TotalDownloads CRAN MonthlyDownloads

This is an R package to help users to easily reproduce charts that are displayed on Public Health England’s Fingertips data tool. Along with the fingertipsR package, this package can be used to help users bring the data on the website into their own outputs.



Get the latest released, stable version from CRAN:


With devtools

You can install the latest development version from github using devtools:

# install.packages("devtools")
                         build_vignettes = TRUE)

From zip

Download this repository from GitHub and either build from source or do the following, that also requires devtools:

source <- devtools:::source_pkg("C:/path/to/fingertipscharts-master")

Base R instructions

To install the package without the use of CRAN or devtools, download the .tar.gz file and then run:

install.packages(path_to_file, repos = NULL, type="source")

Where path_to_file would represent the full path and file name.

Example of some visualisations

Here are a couple of example visualisations the package provides. See the vignettes for a more comprehensive overview.


df <- fingertips_data(90366) %>%
          filter(Sex == "Male")
p <- trends(df,
            timeperiod = Timeperiod,
            value = Value,
            area = AreaName,
            comparator = "England",
            area_name = "Cambridgeshire",
            fill = ComparedtoEnglandvalueorpercentiles,
            lowerci = LowerCI95.0limit,
            upperci = UpperCI95.0limit,
            title = "Life expectancy at birth",
            subtitle = "Cambridgeshire compared to England",
            xlab = "Year",
            ylab = "Age (years)")

Compare indicators

df <- fingertips_data(c(90362, 90366)) %>%
        group_by(IndicatorID) %>%
        filter(Timeperiod == "2014 - 16" &
                       Sex == "Male") %>%
        ungroup() %>%
        select(IndicatorID, AreaName, Value) %>%
        mutate(IndicatorID = paste0("x", IndicatorID)) %>%
        spread(IndicatorID, Value)
p <- compare_indicators(df,
                        x = x90362,
                        y = x90366,
                        xlab = "Healthy life expectancy at birth",
                        ylab = "Life expectancy at birth",
                        highlight_area = c("England", "Dorset"),
                        area = AreaName,
                        add_R2 = TRUE)


fingertipscharts 0.0.6

  • display.values argument added to compare_areas() function - allowing users to display the values alongside the bars in the chart

fingertipscharts 0.0.5 (2019-04-08)

  • area_profiles() - users have control on number of decimal places to display non-count values at (including different decimal places for different indicators)

fingertipscharts 0.0.4 (2019-02-07)

  • added copyright_year argument to map function
  • improved code coverage
  • area_profiles() now should display the "Best/Highest" label better

fingertipscharts 0.0.3 (2018-12-12)

  • Improved functionality for area_profiles() to accept field names other than IndicatorName and Polarity for those two arguments

fingertipscharts 0.0.2 (2018-09-14)

  • Added detail around the area_profiles() function
  • Added create_test_data()

fingertipscharts 0.0.1

Due to popular demand, fingertipscharts has been created to help users create the charts they see on Public Health England's Fingertips website. There is an accompanying vignette that shows users the potential of the functions browseVignettes("fingertipscharts")

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


0.0.11 by Sebastian Fox, 5 months ago

Report a bug at

Browse source code at

Authors: Sebastian Fox [aut, cre]

Documentation:   PDF Manual  

GPL-3 license

Imports dplyr, geojsonio, ggplot2, httr, leaflet, purrr, rlang, scales, sf, stats, stringr, tibble, tidyr, utils

Suggests gdtools, knitr, rmarkdown, testthat, vdiffr

See at CRAN