Package 'VOWR'

Title: Vital Operational Waiting Risk for Healthcare Systems
Description: Provides tools for analysing monthly Referral-to-Treatment (RTT) panel data in healthcare systems. The package supports provider profiling, waiting-time risk classification, risk visualisation, and survival-based threshold-breach modelling. It is designed for applied statisticians, operational researchers, and healthcare analysts interested in identifying high-risk provider trajectories and monitoring deterioration in elective-care performance.
Authors: Muhammad Zahir Khan [aut, cre] (ORCID: <https://orcid.org/0009-0005-7645-8960>)
Maintainer: Muhammad Zahir Khan <[email protected]>
License: MIT + file LICENSE
Version: 0.1.0
Built: 2026-05-21 08:40:41 UTC
Source: https://github.com/zerish12/vowr

Help Index


Kaplan-Meier plot by group

Description

Kaplan-Meier plot by group

Usage

plot_km_by_delay(data, time, event, group)

Arguments

data

A data frame.

time

Name of duration/time variable.

event

Name of event variable: 1 = event occurred, 0 = censored.

group

Name of grouping variable.

Value

A survminer ggsurvplot object.


Estimate Cox proportional hazards model for threshold breach

Description

Estimate Cox proportional hazards model for threshold breach

Usage

vowr_cox_model(surv_profile)

Arguments

surv_profile

Data frame from vowr_survival_merge()

Value

A fitted Cox proportional hazards model


Flag high-risk providers

Description

Flag high-risk providers

Usage

vowr_flag(profile, wait_threshold = 18, vol_percentile = 0.9)

Arguments

profile

A data frame produced by vowr_profile()

wait_threshold

The mean wait time threshold (default 18 weeks)

vol_percentile

The percentile for volatility (default 0.90)

Value

The profile data frame with a 'risk_flag' column


Import and validate RTT data

Description

Import and validate RTT data

Usage

vowr_import(path = NULL)

Arguments

path

Optional path to an NHS RTT CSV file. If NULL, the example data included in the package is loaded.

Value

A cleaned data frame


Kaplan-Meier plot by provider risk group

Description

Kaplan-Meier plot by provider risk group

Usage

vowr_km_by_risk(surv_profile)

Arguments

surv_profile

Data frame from vowr_survival_merge()

Value

A survminer Kaplan-Meier plot object


Visualize provider risk distribution

Description

Visualize provider risk distribution

Usage

vowr_plot(flagged_data)

Arguments

flagged_data

A data frame produced by vowr_flag()

Value

A ggplot object


Profile NHS provider performance

Description

Profile NHS provider performance

Usage

vowr_profile(data)

Arguments

data

A data frame from vowr_import()

Value

A summary table of mean, median, and volatility


Estimate time-to-breach survival model

Description

Estimate time-to-breach survival model

Usage

vowr_survival(data, threshold = 18)

Arguments

data

A data frame from vowr_import()

threshold

The mean wait weeks threshold (default 18)

Value

A list containing the survival object and plot data


Merge survival output with provider profile and risk flags

Description

Merge survival output with provider profile and risk flags

Usage

vowr_survival_merge(surv_result, profile, flagged)

Arguments

surv_result

Output from vowr_survival()

profile

Output from vowr_profile()

flagged

Output from vowr_flag()

Value

A provider-level survival analysis data frame


Run complete VOWR workflow

Description

Run complete VOWR workflow

Usage

vowr_workflow(data, wait_threshold = 18, vol_percentile = 0.9)

Arguments

data

A data frame from vowr_import()

wait_threshold

Waiting-time breach threshold. Default is 18 weeks.

vol_percentile

Volatility percentile for risk flagging. Default is 0.90.

Value

A list containing profile, flagged data, risk plot, survival output, survival profile, Cox model, and Kaplan-Meier plot by risk group.