funBaBSimHospital: Optimization of the BaBSim.Hospital Simulator

View source: R/funBabsimHospital.R

funBaBSimHospitalR Documentation

Optimization of the BaBSim.Hospital Simulator

Description

funBaBSimHospital implements an interface to the babsim.hospital package. babsim.hospital is a discrete-event simulation model for a hospital resource planning problem. The project is motivated by the challenges faced by health care institutions in the COVID-19 pandemic. It can be used by health departments to forecast demand for intensive care beds, ventilators, and staff resources. funBaBSimHospital provides an interface to getTrainTestObjFun.

Usage

funBaBSimHospital(
  x,
  region = 5374,
  nCores = 2,
  verbosity = 0,
  rkiEndDate = "2020-12-09",
  icuEndDate = "2020-12-09",
  trainingWeeksSimulator = 10,
  trainingWeeksField = 6,
  totalRepeats = 10
)

Arguments

x

matrix of points to evaluate with the simulator. Rows for points and columns for dimension.

region

integer. Represents the region code. Default: 5374 (Oberberg).

nCores

integer. Defines the number of cores.

verbosity

integer. Handles output. Default: 0

rkiEndDate

characters. Last day of rki data. Default "2020-12-09"

icuEndDate

characters. Last day of icu data. Default "2020-12-09"

trainingWeeksSimulator

integer. Training period using rki data. Default: 10. Should be larger than trainingWeeksField.

trainingWeeksField

integer. Training period using icu data. Default: 6. Should be smaller than trainingWeeksSimulator.

totalRepeats

integer. Number of repeats for each configuration. Should be a multiple of nCores. Default: 10.

Value

y numeric function value.

Examples


BABSIM_HOSPITAL <- FALSE
if(BABSIM_HOSPITAL){
## babsim.hospital version must be greater equal 11.7:
ver <-  unlist(packageVersion("babsim.hospital"))
if( ver[1] >= 11 & ver[2] >= 7){
    x <- matrix(as.numeric(babsim.hospital::getParaSet(5374)[1,-1]),1,)
    funBaBSimHospital(x)
}
}


babsim.hospital documentation built on May 30, 2022, 9:05 a.m.