m4_poe_detail: Access supplementary information for orders made by providers...

Description Usage Arguments Details Value Examples

View source: R/m4_hosp.R

Description

This function provides base access to the poe_detail table containing data representing further information on POE orders. The table uses an Entity-Attribute-Value (EAV) model: the entity is poe_id, the attribute is field_name, and the value is field_value. EAV tables allow for flexible description of entities when the attributes are heterogenous.

Usage

1
m4_poe_detail(con, cohort = NULL, ...)

Arguments

con

A bigrquery::bigquery() DBIConnection object, as returned by DBI::dbConnect() with an appropriate bigrquery::bigquery() DBI driver specified in the call.

cohort

an optional vector of patient IDs defining the cohort of interest

...

additional optional passed along parameters.

Details

Table attributes for poe_detail table:

(PKEY poe_id, poe_seq)

(FKEY subject_id) -> patients table

(FKEY poe_id) -> poe table

Value

a tibble with the results.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# To run examples, you must have the BIGQUERY_TEST_PROJECT environment
# variable set to name of project which has billing set up and to which
# you have write access.
con <- bigrquery::dbConnect(
  bigrquery::bigquery(),
  project = bigrquery::bq_test_project(),
  quiet = TRUE
)

pod <- m4_poe_detail(con, cohort = 10137012)
dim(pod)

bigrquery::dbDisconnect(con)

hdshea/MIMIC4db documentation built on Dec. 20, 2021, 3:45 p.m.