R6 class representing a health unit e.g. a GP practice or hospital.
Source:R/health_unit.R
health_unit.RdR6 class representing a health unit e.g. a GP practice or hospital.
R6 class representing a health unit e.g. a GP practice or hospital.
Public fields
.metadataA data.frame storing meatadata for health unit
.dataA data.frame storing health statistics for health unit.
Methods
Method datatable()
Create datatable of health unit data
Arguments
type(character(1))
Character specifying summary type. Seesummary_typesfor options....Passed to method.
Examples
x <- example_gp_unit()
x[["datatable"]](type = "population_summary")
x <- example_hospital_unit()
x[["datatable"]](type = "specialty_summary")Examples
## ------------------------------------------------
## Method `health_unit$datatable`
## ------------------------------------------------
x <- example_gp_unit()
x[["datatable"]](type = "population_summary")
x <- example_hospital_unit()
x[["datatable"]](type = "specialty_summary")