Giter Club home page Giter Club logo

phe_nasss_cardiac's Introduction

PHE_NASSS_Cardiac

Extracting and tidying up data from graphs in the National Ambulance Syndromic Surveillance System (England)

I extracted Cardiac/Respiratory Arrest data from graphs in five publications from the UK Health Security Agency/Public Health England bulletins on the NASSS. The five publications were:

https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/860059/NASS_Bulletin_2020_03.pdf

2020 Ambulance bulletin - cardiac

https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/871917/NASS_Bulletin_2020_10.pdf

2020 Ambulance bulletin (week 10) - cardiac

https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/954014/NASS_Bulletin_2021_02.pdf

2021 Ambulance bulletin - cardiac

https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/966198/NASS_Bulletin_2021_08.pdf

2021 Ambulance bulletin (week 08) - cardiac

https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/1050383/UKHSA_NASS_Bulletin_2022_03.pdf

2022 Ambulance bulletin - cardiac

How the graphs were processed

The copied graphs were uploaded into WebPlotDigitizer (https://automeris.io/WebPlotDigitizer/) after some mild modification with GIMP (https://www.gimp.org) to remove gridlines and the daily data trace.

This graph shows all the data from the four reports plotted together. 2022-02-21 NASSS Cardiac Calls (reduced y range)

This graph shows which data from each report was used. It also shows interpolated points (in grey) used to fill the gaps between datapoints read using WebPlotDigitizer.

2022-02-21 NASSS Cardiac Calls (points)

Data was saved as .csv files then tidied in R (https://cran.r-project.org/) to remove duplicates and combine the datasets. Simple graphs were made using ggplot2 (https://ggplot2.tidyverse.org).

Licence

The data and reports shared here are available under the Open Government Licence (https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/)

Acknowledgements

The graph style with lines showing where each year starts and ends, and labels for each year, was developed using example code from http://www.jasonfabris.com/blog/dteformat/

phe_nasss_cardiac's People

Contributors

bk75r avatar

Watchers

 avatar  avatar

phe_nasss_cardiac's Issues

Interpolate between points to find full sum of calls for baseline and 7 day average

PHS_NASSS_Cardiac_WebPlotDigitizerSaveData.R uses (for example)

cardiac.2020 %>%
  summarise(Daily = sum(SevenDayAverage,na.rm = TRUE),Baseline = sum(Baseline))

This just sums the data extracted using WebPlotDigitizer - this isn't the full sum of calls.

The code should interpolate (spline?) between extracted points to find full daily calls for baseline and 7 day average.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.