Learn R Programming

WARDEN (version 2.0.0)

has_event: Check if a patient has a specific event in the queue

Description

Check if a patient has a specific event in the queue

Usage

has_event(event_name, ptr, patient_id, exclude_inf = FALSE)

Value

Logical, TRUE if the event exists for the patient (optionally excluding Inf), FALSE otherwise.

Arguments

event_name

Character string, the name of the event.

ptr

The event queue pointer. Defaults to cur_evtlist.

patient_id

The patient ID. Defaults to i.

exclude_inf

Logical, whether to exclude events with Inf time. Default is FALSE.