inpatient: inpatient

View source: R/inpatient.R

inpatientR Documentation

inpatient

Description

Determines whether a record meets the criteria for an inpatient. Will return 1 if the patient is an inpatient, day patient or emergency assessment and is in an NHS acute trust at time of specimen.

Usage

inpatient(patient_category, patient_location)

Arguments

patient_category

character giving the admission category

patient_location

character giving the patient location at time of specimen

Value

Numeric variable 1 for inpatients, 0 for other

Examples

data(line_listing)

line_listing$inpatient <- inpatient(
    as.character(line_listing$patient_category),
    as.character(line_listing$patient_location))

PublicHealthEngland/hcaidcs documentation built on Jan. 19, 2024, 8:38 a.m.