An R package to make it easy to view, copy, interact and publish the data products resulting from the Access to Care analysis. It also contains handly utlity functions, and the data needed to create a consistent set of examples across the multiple data product types.
This project combines US CENSUS population data with hospital data provided by Medicare. A linear model is used to determine if a county is over, or under served based on the size of the population.
Install accesstocare
from GitHub using:
devtools::install_github("sol-eng/accesstocare")
To view the available examples, use atc_packate_content()
. It returns a list
object with all of the available content. It is presented in the console, or RMarkdown, as a table.
atc_package_content()
#> No. Name Type
#> 1 connectwidgets Report
#> 2 dash Dashboard
#> 3 flexdashboard Dashboard
#> 4 htmlwidgets Plot
#> 5 jupyter Jupyter
#> 6 launcher-programatic Launcher
#> 7 plot Plot
#> 8 plumber-api REST API
#> 9 powerpoint PowerPoint
#> 10 powerpoint-state PowerPoint
#> 11 presentation Presentation
#> 12 RMarkdown-DataPrep Scheduled R Script
#> 13 RMarkdown-html Report
#> 14 RMarkdown-pdf Report
#> 15 RNotebook Notebook
#> 16 shiny Dashboard
There are three ways to use the examples:
atc_open_content()
atc_copy_content()
atc_copy_all_content()
#> No. Name Type
#> 1 connectwidgets Report
#> 2 dash Dashboard
#> 3 flexdashboard Dashboard
#> 4 htmlwidgets Plot
#> 5 jupyter Jupyter
#> 6 launcher-programatic Launcher
#> 7 plot Plot
#> 8 plumber-api REST API
#> 9 powerpoint PowerPoint
#> 10 powerpoint-state PowerPoint
#> 11 presentation Presentation
#> 12 RMarkdown-DataPrep Scheduled R Script
#> 13 RMarkdown-html Report
#> 14 RMarkdown-pdf Report
#> 15 RNotebook Notebook
#> 16 shiny Dashboard
#> 17 Cancel
#> Enter the content number:
Enter the number to the left of the example in order to run it. For example, to open the flexdashboard
example, type 3 and press enter.
To run an example without the prompt, pass the content_no
argument with the number. Again, to open the flexdashboard
use:
An example can be copied to your working directory by using atc_copy_content()
. It will create a new sub-folder and load the files for that particular example.
It has the same interactive mechanism as the open example function.
#> No. Name Type
#> 1 connectwidgets Report
#> 2 dash Dashboard
#> 3 flexdashboard Dashboard
#> 4 htmlwidgets Plot
#> 5 jupyter Jupyter
#> 6 launcher-programatic Launcher
#> 7 plot Plot
#> 8 plumber-api REST API
#> 9 powerpoint PowerPoint
#> 10 powerpoint-state PowerPoint
#> 11 presentation Presentation
#> 12 RMarkdown-DataPrep Scheduled R Script
#> 13 RMarkdown-html Report
#> 14 RMarkdown-pdf Report
#> 15 RNotebook Notebook
#> 16 shiny Dashboard
#> 17 Cancel
#> Enter the content number:
To avoid the interactive menu, pass the number to the left of the example, as an argument of the function:
atc_copy_content(3) # Copies the `flexdashboard` folder
atc_copy_all_content()
will copy all of the examples. It will as many sub-folders as there are examples available.