Skip to contents

Calculate some stats about removals

Usage

wl_removal_stats(waiting_list, start_date = NULL, end_date = NULL)

Arguments

waiting_list

dataframe. A df of referral dates and removals

start_date

date. The start date to calculate from

end_date

date. The end date to calculate to

Value

dataframe. A df containing number of removals, mean capacity, and the coefficient of variation of removals

Examples

referrals <- c.Date("2024-01-01", "2024-01-04", "2024-01-10", "2024-01-16")
removals <- c.Date("2024-01-08", NA, NA, NA)
waiting_list <- data.frame("referral" = referrals, "removal" = removals)
removal_stats <- wl_removal_stats(waiting_list)

# TODO : referral <- arrival
# debug and test
# simplify notation
# add detail to params above
# arrival mean and variance