knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%" )
The goal of cov20 is to provide the user the opportunity to launch an interactive shiny application and visualize the statistics related to coronavirus from around the world. The package also contains a function that will help the user launch the application. In order to launch the application, 3 datasets have been included in this package.
A development version of the package can be installed from GitHub with:
# install.packages("devtools") devtools::install_github("etc5523-2020/r-package-assessment-jthoma48")
This is a basic example which shows you how to launch the app:
library(cov20) launch_app()
This is a basic example of how you can access a dataset and visualize it however you want:
library(cov20)
data2
You can access these datasets: data2, data3 and data5
Besides the launch_app()
function, there are 2 more functions in this package:
selectui01()
: creates a drop-down list and displays options for countries and states to select from in the applicationselectui01(inputId)
leafserv()
: generates a map of your desired country in the applicationleafserv(df$Long, df$Lat, df$State)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.