Giter VIP home page Giter VIP logo

italy_dash's Introduction

The Covid19 Italy Dashboard

This Covid19 Italy dashboard provides an overview of the 2019 Novel Coronavirus COVID-19 (2019-nCoV) epidemic in Italy. This dashboard is built with R using the Rmakrdown framework and can easily reproduce by others.

Data

The input data for this dashboard are the covis19italy and coronavirus R packages (dev version). The data and dashboard are refreshed on a daily bases.

Data source

The raw data for the covid19italy package is pulled from Italy Department of Civil Protection, and the coronavirus package from Johns Hopkins University Center for Systems Science and Engineering (JHU CCSE)

Packages

  • Dashboard interface - the flexdashboard package.
  • Visualization - the plotly package for the plots and mapview package for the map
  • Data manipulation - dplyr, and tidyr
  • Tables - the DT package

Deployment and reproducibly

The dashboard was deployed to Github docs. If you wish to deploy and/or modify the dashboard on your Github account, you can apply the following steps:

  • Fork the dashboard repository, or
  • Clone it and push it to your Github package
  • Here some general guidance about deployment of flexdashboard on Github page - link

For any question or feedback, you can either open an issue or contact me on Twitter.

italy_dash's People

Contributors

dependabot[bot] avatar ramikrispin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

italy_dash's Issues

Error running in Shiny

Dear Rami,
I create a new project on my R Server using your GitHub repository. The only change was adding: runtime: shiny in the header of the rmarkdown file.
Maybe it depends on the use of leaflet you used in your code? As: rstudio/leaflet#664 (comment)

Running shiny the first time was ok. With a new session I got this error log:

Loading required package: shiny

Listening on http://127.0.0.1:4566
Warning: Error in value[[3L]]: Couldn't normalize path in addResourcePath, with arguments: prefix = 'leaflet-providers-1.9.0'; directoryPath = '/tmp/Rtmp31Vtod'
108: stop
107: value[[3L]]
106: tryCatchOne
105: tryCatchList
104: tryCatch
103: addResourcePath
102: FUN
101: lapply
100: processDeps
99: transform
98: func
96: f
95: Reduce
86: do
85: hybrid_chain
84: origRenderFunc
83: output$reactivedoc
3:
1: rmarkdown::run

Can you help me to understand where is the โ€œbugโ€?
Thanks

China dash

i want to make a China dash, could you help me, thanks.

NA values in some Italian Regions on region map

Dear Rami,
wonderful job first of all.
Just wanted to give few lines of R code you might attach after line
home_conf_color <- "#FDBBBC"
of your index.Rmd script in order to solve the NA values in the dashboard map of Italian regions.

``

rename region in correct way

italy_region$region_name <- gsub("Puglia", "Apulia",italy_region$region_name)
italy_region$region_name <- gsub("Emilia Romagna","Emilia-Romagna" ,italy_region$region_name)
italy_region$region_name <- gsub("Friuli Venezia Giulia" ,"Friuli-Venezia Giulia",italy_region$region_name)
italy_region$region_name <- gsub("Sicilia" ,"Sicily",italy_region$region_name)

merge Bolzano and Trento subregions in one region called Trentino-Alto Adige

trentino <- italy_region %>%
dplyr::filter(grepl("Bolzano|Trento", italy_region$region_name),
date == max(date)) # take max date

rename

trentino$region_name <- gsub("P.A. Bolzano", "Trentino-Alto Adige", trentino$region_name)
trentino$region_name <- gsub("P.A. Trento", "Trentino-Alto Adige", trentino$region_name)

Input common lat and long

trentino$lat[1] <- 46.4337
trentino$lat[2] <- 46.4337
trentino$long[1] <- 11.1693
trentino$long[2] <- 11.1693

trentino <- trentino %>% group_by(date, region_code, region_name, lat, long) %>%
summarise_all(funs(sum)) # summarise subregions values in ONE region

convert to df before rbind

trentino <- as.data.frame(trentino)
italy_region <- rbind(trentino, italy_region)

filter out old subregions values as now not needed

italy_region <- italy_region %>% dplyr::filter(!grepl("P.A. Bolzano|P.A. Trento", region_name))
``

PS: It requires library(tidyverse) within setup chunk of course as I'm using group_by function
Thanks a lot again and greetings from Italy!
Keep the good job!
Best regards

#Giuseppe

Annotation 2020-03-31 165340

Upcoming changes in the coronavirus package (CRAN v0.2.0)

As the many changes occurred since the release of v0.1.0 significant changes in the data structure expected in v0.2.0 (expected to release to CRAN by May 15. Changes are available on the dev-v020 branch

Those changes impact the covid19 Italy dashboard. Please see the following commit with the changes needed to keep the dashboard working.

coronavirus 0.2.0

  • Data changes:
    • coronavirus dataset - Change the structure of the US data from March 23rd, 2020 and forward. The US data is now available on an aggregated level. More information about the changes in the raw data available on this issue
    • Changes in the columns names and order:
      • Province.State changed to province
      • Country.Region changed to country
      • Lat changed to lat
      • Long changed to long
    • The covid_south_korea and covid_iran that were avialble on the dev version were removed from the package and moved to new package covid19wiki, for now available only on Github

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.