Skip to contents

A small, fabricated dataset representing a separately queried HasBeenAdmitted = 1 ESSENCE query, purpose-built to demonstrate link_encounters() two-pull linkage in vignette("encounter-linkage") alongside essence_ed_raw. All facility names, visit identifiers, patient identifiers, and geographic values are entirely synthetic. No real patient or facility data are included.

Usage

essence_inp_raw

Format

A data frame with approximately 6 rows and 19 columns. Same column structure as essence_raw, plus HasBeenI (see Details); see essence_raw's documentation for the other column definitions.

Source

Entirely synthetic. Generated by data-raw/generate_synthetic_data.R.

Details

Visit types included

Continuity-break admission half

2 rows (HasBeenE = 0, HasBeenAdmitted = 1) sharing HospitalName x Visit_ID with a real row in essence_ed_raw: the mis-submitted direct-admit continuation of an ED visit reported as two unrelated records.

Genuine direct admission

4 rows (HasBeenE = 0, HasBeenAdmitted = 1) with a Visit_ID that appears nowhere in essence_ed_raw: true direct admissions with no preceding ED visit at all, structurally invisible to a HasBeenE = 1 query.

HasBeenI = 1 for every row here, mirroring HasBeenAdmitted, as real ESSENCE data typically has them move together for a genuine admission. Every has_been_* column, including has_been_i, is guaranteed a real 0/1 value with no NA in this dataset and in essence_ed_raw; the two combined never produce an NA has_been_* column in link_encounters()'s output.