1 Introduction

The PEDALFAST (PEDiatric vALidation oF vAriableS in TBI) project was a prospective cohort study conducted at multiple American College of Surgeons freestanding level I Pediatric Trauma Centers. The cohort consists of patients under 18 years of age who were admitted to the intensive care unit (ICU) with an acute traumatic brain injury (TBI) diagnosis and Glasgow Coma Scale (GCS) score not exceeding 12 or a neurosurgical procedure (intracranial pressure [ICP] monitor, external ventricular drain [EVD], craniotomy, or craniectomy) within the first 24 hours of admission.

This data set was used for several publications:

  • Bennett, DeWitt, Greene, et al. (2017)
  • Bennett, DeWitt, Dixon, et al. (2017)
  • Bennett et al. (2016)

Funded by NICHD grant number R03HD094912 we retroactively mapped the data collected by the PEDALFAST project the Federal Interagency Traumatic Brain Injury Research (FITBIR) data standard. The R data package pedalfast.data provides the data submitted to FITBIR as both raw files and in ready to use R data sets.

The PEDALFAST study data were collected and managed using REDCap electronic data capture tools hosted at the University of Colorado Denver. (Harris et al. 2009) REDCap (Research Electronic Data Capture) is a secure, web-based application designed to support data capture for research studies, providing 1) an intuitive interface for validated data entry; 2) audit trails for tracking data manipulation and export procedures; 3) automated export procedures for seamless data downloads to common statistical packages; and 4) procedures for importing data from external sources.

This vignette documents the provided data set and other utilities of this package.

2 Provided Data Sets

The pedalfast.data package provides the following data objects:

data(package = "pedalfast.data")$results[, c("Item", "Title")]
##      Item                 Title               
## [1,] "pedalfast"          "PEDALFAST Data"    
## [2,] "pedalfast_metadata" "PEDALFAST Metadata"

Each of these objects will be described in detail in the following sections.

The provided data sets are data.frames. Examples for working with the provided data sets will be done using base R, the tidyverse, and data.table. Click the following buttons to have the different data paradigms displayed or not while reading this vignette.

3 PEDALFAST Data

The data collected during the PEDALFAST study has been provided in two data.frames so the end user may opt into using another paradigm such as data.table or the tidyverse. The following will focus on use of base R methods only.

Reproduction of the examples in this vignette will require the following namespaces.

library(pedalfast.data)

Load the provided data sets into the active session via data as follows.

data(pedalfast,          package = "pedalfast.data")
data(pedalfast_metadata, package = "pedalfast.data")

str(pedalfast,          max.level = 0)
## 'data.frame':    388 obs. of  103 variables:
str(pedalfast_metadata, max.level = 0)
## 'data.frame':    103 obs. of  3 variables:

The pedalfast is a data frame with each row reporting the collected data for one subject, and each column being a unique variable. The pedalfast_metadata data frame is a selection of columns from the data dictionary provided by a REDCap export of the project. In the following you will find examples of specific utilities provided in this package to make formatting the data easier.

Let’s look at the first three columns of pedalfast, and the first three rows of pedalfast_metadata.

head(pedalfast[, 1:3])
##   studyid  age female
## 1     102 1179      0
## 2     103   90      0
## 3     110 1164      1
## 4     112 1413      1
## 5     114  233      0
## 6     116 5791      0
pedalfast_metadata[1:3, ]
##   variable                        description         values
## 1  studyid               PEDALFAST Patient ID           <NA>
## 2      age Age, in days, at time of admission           <NA>
## 3   female             Is the patient female? 0, no | 1, yes

The first column of pedalfast is the studyid, and the first row of pedalfast_metadata is the documentation for the studyid. Similarly, the second column of pedalfast and second row of pedalfast_metadata are for the age of the patient. The first notable change in is in the third row of the pedalfast_metadata where the indicator for female is documented including the mapping from integer to English: 0, no | 1, yes

The rest of this section of the vignette provides details on each of the variables in the data set and provides some examples for data use.

3.1 Study ID

The PEDALFAST data was collected at multiple sites. The study id provided is a patient specific random number between 100 and 999 with no mapping to the sites. That is, you should not be able to determine which site provided a specific row of data.

knitr::kable(subset(pedalfast_metadata, variable == "studyid"))
variable description values
studyid PEDALFAST Patient ID NA
str(pedalfast$studyid)
##  int [1:388] 102 103 110 112 114 116 120 122 123 124 ...

3.2 Age

Age of the patient is reported in days.

knitr::kable(subset(pedalfast_metadata, variable == "age"))
variable description values
2 age Age, in days, at time of admission NA
summary(pedalfast$age)          # in days
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##     0.0   679.5  2508.5  2699.3  4635.5  6501.0
summary(pedalfast$age / 365.25) # in years
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##   0.000   1.860   6.868   7.390  12.691  17.799

The PEDALFAST data has been submitted to the Federal Interagency Traumatic Brain Injury Research (FITBIR) Informatics System. As part of that submission age of the patient was to be reported as the floor of the patients age in years with the exception of those under one year of age. For those under one year of age the reported value was to be the truncated three decimal age in years. For example, a patient more than one month but less than two months would have a reported age of 0.083 (1/12), a 8 month old would have a reported age of 0.666 (8/12). Note the truncation of the decimal. If you require the same rounding scheme we have provided a function in this package round_age to provide the rounding with the truncation. The function will return age as a character by default, a numeric value will be returned when specified.

fitbir_ages <-
  data.frame(age  = pedalfast$age / 365.25,
             char = round_age(pedalfast$age / 365.25),
             num  = round_age(pedalfast$age / 365.25, type = "numeric"))

plot(fitbir_ages$age, fitbir_ages$num, xlab = "Age (years)", ylab = "FITBIR Age (Years)")

3.3 Female/Male

The variable female is an indicator for sex/gender. The category of female/male was made by the attending physicians or reported by the patient/caregivers. This variable was not determined by sex chromosomes genotyping. The intent was to report sex but gender, the social constructed identify of sex, might be more appropriate.

knitr::kable(subset(pedalfast_metadata, variable == "female"))
variable description values
3 female Is the patient female? 0, no | 1, yes
sum(pedalfast$female)
## [1] 149
mean(pedalfast$female)
## [1] 0.3840206

3.4 Injury

Three variables related to injury. The source of information for the injury and the injury mechanism (injurymech) are both categorical variables with known values and are presented as character vectors in the pedalfast data.frame. The time from injury to admission (injurytoadmit) is reported in days, if the date of injury was known.

inj_vars <- c("sourceinj", "injurytoadmit", "injurymech")
knitr::kable(subset(pedalfast_metadata, variable %in% inj_vars))
variable description values
4 sourceinj Source of Injury Information NA
5 injurytoadmit Days from injury, if known, to admission. NA
6 injurymech Injury mechanism 1, traffic | 2, fall | 3, known or suspected abuse | 4, self-harm | 9, other
summary(pedalfast[, inj_vars])
##   sourceinj         injurytoadmit      injurymech       
##  Length:388         Min.   :  0.000   Length:388        
##  Class :character   1st Qu.:  0.000   Class :character  
##  Mode  :character   Median :  0.000   Mode  :character  
##                     Mean   :  1.415                     
##                     3rd Qu.:  0.000                     
##                     Max.   :366.000                     
##                     NA's   :41

The injurymech is a character vector by default so the end user may build a factor as needed.

table(pedalfast$injurymech, useNA = "always")
## 
##                     Fall Known or suspected abuse                    Other 
##                       72                       91                       77 
##                Self-harm                  Traffic                     <NA> 
##                        6                      142                        0

3.5 Emergency Department

Several variables were collected in both the emergency department (ED) and the intensive care unit (ICU). The following are the notes for the variables collected in the ED.

3.5.1 GCS

The Glasgow Coma Score was assessed in one or both of the Emergency Department (ED) and the ICU. There are several variables noted here for GCS with the suffix ‘ed’ which are also reported later from the ICU with the suffix ‘icu’.

knitr::kable(subset(pedalfast_metadata, grepl("^gcs.*ed$", variable)))
variable description values
7 gcsyned Was a GCS obtained in the ED? 0, no | 1, yes
8 gcseyeed ED GCS Eye 4, spontaneous | 3, to speech | 2, to pain only | 1, no response
9 gcsverbaled ED GCS Verbal 5, oriented, appropriate or coos and babbles | 4, confused or irritable cries | 3, inappropriate words or cries to pain | 2, incomprehensible sounds or moans to pain | 1, no response
10 gcsmotored ED GCS Motor 6, obeys commands | 5, localizes pain or withdraws to touch | 4, withdraws from painful stimuli | 3, abnormal flexion to pain | 2, abnormal extension to pain | 1, no response/flaccid
11 gcsed ED GCS Total [gcseyeed]+[gcsverbaled]+[gcsmotored]
12 gcsetted Was the patient intubated at the time of their ED GCS assessment? 0, no | 1, yes
13 gcsseded Was the patient sedated at the time of their ED GCS assessment? 0, no | 1, yes
14 gcspared Was the patient chemically paralyzed at the time of their ED GCS assessment? 0, no | 1, yes
15 gcseyeobed Were the patient’s eyes obscured by injury, swelling, or bandage at the time of their ED GCS assessment? 0, no | 1, yes
summary(pedalfast[, grep("^gcs.*ed$", names(pedalfast))])
##     gcsyned          gcseyeed      gcsverbaled      gcsmotored   
##  Min.   :0.0000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:1.0000   1st Qu.:1.000   1st Qu.:1.000   1st Qu.:1.000  
##  Median :1.0000   Median :1.000   Median :1.000   Median :4.000  
##  Mean   :0.9835   Mean   :1.677   Mean   :1.595   Mean   :3.326  
##  3rd Qu.:1.0000   3rd Qu.:2.000   3rd Qu.:1.000   3rd Qu.:5.000  
##  Max.   :1.0000   Max.   :4.000   Max.   :5.000   Max.   :6.000  
##  NA's   :24       NA's   :20      NA's   :20      NA's   :20     
##      gcsed           gcsetted         gcsseded         gcspared     
##  Min.   : 3.000   Min.   :0.0000   Min.   :0.0000   Min.   :0.0000  
##  1st Qu.: 3.000   1st Qu.:0.0000   1st Qu.:0.0000   1st Qu.:0.0000  
##  Median : 6.000   Median :1.0000   Median :1.0000   Median :0.0000  
##  Mean   : 6.598   Mean   :0.7371   Mean   :0.6158   Mean   :0.1355  
##  3rd Qu.: 9.000   3rd Qu.:1.0000   3rd Qu.:1.0000   3rd Qu.:0.0000  
##  Max.   :15.000   Max.   :1.0000   Max.   :1.0000   Max.   :1.0000  
##  NA's   :20       NA's   :19       NA's   :21       NA's   :19      
##    gcseyeobed     
##  Min.   :0.00000  
##  1st Qu.:0.00000  
##  Median :0.00000  
##  Mean   :0.04905  
##  3rd Qu.:0.00000  
##  Max.   :1.00000  
##  NA's   :21

GCS for the eye, verbal, and motor can be used as both numeric values (as reported in the pedalfast data.frame) or as a categorical variable. The pedalfast.data package provides functions for quickly mapping from the numeric values to a factor for gcs. The functions gcs_as_integer and gcs_as_factor

While GCS is a common assessment, the specific language used may vary. By providing these functions we are able to report the exact language used on the assessment.

Lower numeric values of GCS correspond to lower neurological functioning. To illustrate this consider, mapping the integer values 1 through 6 to the labels for the GCS scales:

knitr::kable(
             data.frame(integers = 1:6,
                        eye      = gcs_as_factor(1:6, scale = "eye"),
                        motor    = gcs_as_factor(1:6, scale = "motor"),
                        verbal   = gcs_as_factor(1:6, scale = "verbal"))
)
integers eye motor verbal
1 No response No response/flaccid No response
2 To pain only Abnormal extension to pain Incomprehensible sounds or moans to pain
3 To speech Abnormal flexion to pain Inappropriate words or cries to pain
4 Spontaneous Withdraws from painful stimuli Confused or irritable cries
5 NA Localizes pain or withdraws to touch Oriented, appropriate or coos and babbles
6 NA Obeys commands NA

By default, the mapping of the integer values to factor levels will map the the integer value of 1 to level 1. The argument highest_first will reverse the order of the levels. This option has been provided to help make setting a logical reference level for modeling. For example, say we want to estimate hospital length of stay by the motor GCS score.

gcs_example_data <-
  data.frame(los = pedalfast$hosplos,
             motor_int = pedalfast$gcsmotored,
             motor_f1  = gcs_as_factor(pedalfast$gcseyeed, scale = "eye"),
             motor_f2  = gcs_as_factor(pedalfast$gcseyeed, scale = "eye", highest_first = TRUE))

head(gcs_example_data)
##   los motor_int     motor_f1     motor_f2
## 1  22         4  No response  No response
## 2  24         2  No response  No response
## 3   9         4 To pain only To pain only
## 4   6         5  Spontaneous  Spontaneous
## 5  40         6  No response  No response
## 6  36         5  No response  No response

Just looking at the summary of the example data set shows the order of the factor is different

summary(gcs_example_data)
##       los           motor_int             motor_f1           motor_f2  
##  Min.   :  0.00   Min.   :1.000   No response :262   Spontaneous : 63  
##  1st Qu.:  4.00   1st Qu.:1.000   To pain only: 26   To speech   : 17  
##  Median :  9.00   Median :4.000   To speech   : 17   To pain only: 26  
##  Mean   : 16.42   Mean   :3.326   Spontaneous : 63   No response :262  
##  3rd Qu.: 20.00   3rd Qu.:5.000   NA's        : 20   NA's        : 20  
##  Max.   :345.00   Max.   :6.000                                        
##                   NA's   :20

Thus, simple regression models will use either “no response” or “spontaneous” as the reference level. Pick the one you want to use.

summary(lm(los ~ motor_int, data = gcs_example_data))$coef
##               Estimate Std. Error   t value     Pr(>|t|)
## (Intercept) 18.0227121   2.522281  7.145402 4.888884e-12
## motor_int   -0.7029069   0.652196 -1.077754 2.818534e-01
summary(lm(los ~ motor_f1,  data = gcs_example_data))$coef
##                        Estimate Std. Error    t value     Pr(>|t|)
## (Intercept)           17.778626   1.515932 11.7278505 3.659209e-27
## motor_f1To pain only  -3.163241   5.045327 -0.6269646 5.310755e-01
## motor_f1To speech    -10.131567   6.141259 -1.6497541 9.985587e-02
## motor_f1Spontaneous   -8.191324   3.443112 -2.3790466 1.787242e-02
summary(lm(los ~ motor_f2,  data = gcs_example_data))$coef
##                       Estimate Std. Error    t value    Pr(>|t|)
## (Intercept)           9.587302   3.091435  3.1012462 0.002077399
## motor_f2To speech    -1.940243   6.706264 -0.2893180 0.772502781
## motor_f2To pain only  5.028083   5.719637  0.8790913 0.379931737
## motor_f2No response   8.191324   3.443112  2.3790466 0.017872422

The total GCS score is provided.

summary(pedalfast$gcsed)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
##   3.000   3.000   6.000   6.598   9.000  15.000      20

Be careful with factors. Recall that factors are numeric vectors with the first level mapped to the value one, regardless if that is logical or not. Thus:

identical(pedalfast$gcsed,
          pedalfast$gcseyeed + pedalfast$gcsmotored + pedalfast$gcsverbaled)
## [1] TRUE

identical(pedalfast$gcsed,
          as.integer(gcs_as_factor(pedalfast$gcseyeed, "eye")) +
          as.integer(gcs_as_factor(pedalfast$gcsmotored, "motor")) +
          as.integer(gcs_as_factor(pedalfast$gcsverbaled, "verbal")))
## [1] TRUE

identical(pedalfast$gcsed,
          as.integer(gcs_as_factor(pedalfast$gcseyeed, "eye", highest_first = TRUE)) +
          as.integer(gcs_as_factor(pedalfast$gcsmotored, "motor", highest_first = TRUE)) +
          as.integer(gcs_as_factor(pedalfast$gcsverbaled, "verbal", highest_first = TRUE)))
## [1] FALSE

3.5.2 Disposition

Disposition form the emergency department:

knitr::kable(subset(pedalfast_metadata, variable == "eddisposition"))
variable description values
16 eddisposition Where did the patient go when they left the ED? NA
table(pedalfast$eddisposition, useNA = "always")
## 
## Intensive Care Unit      Operating Room               Other                <NA> 
##                 313                  57                   2                  16

3.6 Imaging

If the patient had CT imaging the information is provided in one of the variables prefixed by “ct” with the exception of the time from admission to ct.

knitr::kable(subset(pedalfast_metadata, grepl("^(admitto)*ct", variable)))
variable description values
17 admittoct days between admission at CT imaging Integer (days)
18 ctskullfrac Is the initial head CT positive for skull fracture? 0, no | 1, yes
19 ctce Is the initial head CT positive for cerebral edema or brain swelling? 0, no | 1, yes
20 ctmidlineshift Is the initial head CT positive for midline shift? 0, no | 1, yes
21 ctcompress Is the initial head CT positive for compression or effacement of the basilar cisterns? 0, no | 1, yes
22 ctintraparhem Is the initial head CT positive for intraparenchymal hemorrhage? 0, no | 1, yes
23 ctsubarchhem Is the initial head CT positive for subarachnoid hemorrhage? 0, no | 1, yes
24 ctintraventhem Is the initial head CT positive for intraventricular hemorrhage? 0, no | 1, yes
25 ctsubhematoma Is the initial head CT positive for subdural hematoma? 0, no | 1, yes
26 ctepihematoma Is the initial head CT positive for epidural hematoma? 0, no | 1, yes
head(pedalfast[, grepl("^(admitto)*ct", names(pedalfast))])
##   admittoct ctskullfrac ctce ctmidlineshift ctcompress ctintraparhem
## 1         0           0    1              0          0             1
## 2         0           0    0              0          0             0
## 3         0           0    0              0          0             0
## 4         0           1    0              1          0             0
## 5         0           0    0              1          0             0
## 6         0           1    0              1          0             0
##   ctsubarchhem ctintraventhem ctsubhematoma ctepihematoma
## 1            0              0             0             0
## 2            1              0             1             0
## 3            0              0             0             0
## 4            0              0             1             1
## 5            0              0             1             0
## 6            0              0             1             0
summary(pedalfast[, grepl("^(admitto)*ct", names(pedalfast))])
##    admittoct        ctskullfrac          ctce       ctmidlineshift  
##  Min.   : -5.000   Min.   :0.0000   Min.   :0.000   Min.   :0.0000  
##  1st Qu.:  0.000   1st Qu.:0.0000   1st Qu.:0.000   1st Qu.:0.0000  
##  Median :  0.000   Median :1.0000   Median :0.000   Median :0.0000  
##  Mean   :  4.005   Mean   :0.5065   Mean   :0.426   Mean   :0.2416  
##  3rd Qu.:  0.000   3rd Qu.:1.0000   3rd Qu.:1.000   3rd Qu.:0.0000  
##  Max.   :366.000   Max.   :1.0000   Max.   :1.000   Max.   :1.0000  
##  NA's   :3         NA's   :5        NA's   :3       NA's   :3       
##    ctcompress     ctintraparhem     ctsubarchhem    ctintraventhem  
##  Min.   :0.0000   Min.   :0.0000   Min.   :0.0000   Min.   :0.0000  
##  1st Qu.:0.0000   1st Qu.:0.0000   1st Qu.:0.0000   1st Qu.:0.0000  
##  Median :0.0000   Median :0.0000   Median :0.0000   Median :0.0000  
##  Mean   :0.2494   Mean   :0.3325   Mean   :0.3273   Mean   :0.1273  
##  3rd Qu.:0.0000   3rd Qu.:1.0000   3rd Qu.:1.0000   3rd Qu.:0.0000  
##  Max.   :1.0000   Max.   :1.0000   Max.   :1.0000   Max.   :1.0000  
##  NA's   :3        NA's   :3        NA's   :3        NA's   :3       
##  ctsubhematoma ctepihematoma   
##  Min.   :0.0   Min.   :0.0000  
##  1st Qu.:0.0   1st Qu.:0.0000  
##  Median :1.0   Median :0.0000  
##  Mean   :0.6   Mean   :0.1403  
##  3rd Qu.:1.0   3rd Qu.:0.0000  
##  Max.   :1.0   Max.   :1.0000  
##  NA's   :3     NA's   :3

3.7 ICU

There are several variables groups from the ICU.

3.7.1 Source of information

knitr::kable(subset(pedalfast_metadata, variable == "sourceicu"))
variable description values
27 sourceicu Source of Injury Information NA
table(pedalfast$sourceicu, useNA = "always")
## 
##                ICU MD ICU nursing flowsheet                 Other 
##                   298                    75                     2 
##                  <NA> 
##                    13

3.7.2 Pupil Reactivity

knitr::kable(subset(pedalfast_metadata, variable == "puplrcticu"))
variable description values
28 puplrcticu Pupillary reaction on ICU admission NA
table(pedalfast$puplrcticu, useNA = "always")
## 
##    Both Fixed Both Reactive     One Fixed       Unknown          <NA> 
##            62           284            11            27             4

3.7.3 GCS

GCS in the ICU are similar variables as where noted in the emergency department. Variable names are appended by “icu” for the values attended in the ICU

knitr::kable(subset(pedalfast_metadata, grepl("^gcs.*icu$", variable)))
variable description values
29 gcsynicu Was a GCS obtained on ICU Admission? 0, no | 1, yes
30 gcseyeicu ICU GCS Eye 4, spontaneous | 3, to speech | 2, to pain only | 1, no response
31 gcsverbalicu ICU GCS Verbal 5, oriented, appropriate or coos and babbles | 4, confused or irritable cries | 3, inappropriate words or cries to pain | 2, incomprehensible sounds or moans to pain | 1, no response
32 gcsmotoricu ICU GCS Motor 6, obeys commands | 5, localizes pain or withdraws to touch | 4, withdraws from painful stimuli | 3, abnormal flexion to pain | 2, abnormal extension to pain | 1, no response/flaccid
33 gcsicu ICU GCS Total [gcseyeicu]+[gcsverbalicu]+[gcsmotoricu]
34 gcsetticu Was the patient intubated at the time of their ICU GCS assessment? 0, no | 1, yes
35 gcssedicu Was the patient sedated at the time of their ICU GCS assessment? 0, no | 1, yes
36 gcsparicu Was the patient chemically paralyzed at the time of their ICU GCS assessment? 0, no | 1, yes
37 gcseyeobicu Were the patient’s eyes obscured by injury, swelling, or bandage at the time of their ICU GCS assessment? 0, no | 1, yes
summary(pedalfast[, grepl("^gcs.*icu$", names(pedalfast))])
##     gcsynicu        gcseyeicu      gcsverbalicu    gcsmotoricu   
##  Min.   :0.0000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:1.0000   1st Qu.:1.000   1st Qu.:1.000   1st Qu.:1.000  
##  Median :1.0000   Median :1.000   Median :1.000   Median :4.000  
##  Mean   :0.9757   Mean   :1.737   Mean   :1.441   Mean   :3.632  
##  3rd Qu.:1.0000   3rd Qu.:2.000   3rd Qu.:1.000   3rd Qu.:5.000  
##  Max.   :1.0000   Max.   :4.000   Max.   :5.000   Max.   :6.000  
##  NA's   :18       NA's   :8       NA's   :7       NA's   :8      
##      gcsicu         gcsetticu        gcssedicu        gcsparicu     
##  Min.   : 3.000   Min.   :0.0000   Min.   :0.0000   Min.   :0.0000  
##  1st Qu.: 3.000   1st Qu.:1.0000   1st Qu.:1.0000   1st Qu.:0.0000  
##  Median : 6.000   Median :1.0000   Median :1.0000   Median :0.0000  
##  Mean   : 6.811   Mean   :0.8407   Mean   :0.7723   Mean   :0.1273  
##  3rd Qu.: 9.000   3rd Qu.:1.0000   3rd Qu.:1.0000   3rd Qu.:0.0000  
##  Max.   :15.000   Max.   :1.0000   Max.   :1.0000   Max.   :1.0000  
##  NA's   :8        NA's   :5        NA's   :6        NA's   :11      
##   gcseyeobicu     
##  Min.   :0.00000  
##  1st Qu.:0.00000  
##  Median :0.00000  
##  Mean   :0.09162  
##  3rd Qu.:0.00000  
##  Max.   :1.00000  
##  NA's   :6

3.7.4 Discharge and Readmission to the ICU

The variable admitttoicudc1 is the number of days from admission to discharge from the ICU. If the patient had a readmission to the ICU then the first readmission (second overall admission) occurred admittoicuadmit2 days from admission. The duration of the first readmission (second overall admission) would be the difference between admitttoicudc2 and admittoicuadmit2.

knitr::kable(subset(pedalfast_metadata, grepl("^admittoicu", variable)))
variable description values
38 admittoicudc1 Days from admit to ICU discharge for the initial ICU admission. integer (days)
39 admittoicudc2 Days from admit to ICU discharge for the second ICU admission (first readmission) integer (days)
40 admittoicudc3 Days from admit to ICU discharge for the third ICU admission (second readmission) integer (days)
41 admittoicuadmit2 Days from admit to second ICU admission (first readmission) integer (days)
42 admittoicuadmit3 Days from admit to third ICU admission (second readmission) integer (days)
summary(pedalfast[, grepl("^admittoicu", names(pedalfast))])
##  admittoicudc1     admittoicuadmit2 admittoicudc2    admittoicuadmit3
##  Min.   :  0.000   Min.   :  1.00   Min.   :  5.00   Min.   :34      
##  1st Qu.:  1.000   1st Qu.:  5.00   1st Qu.:  7.75   1st Qu.:34      
##  Median :  3.000   Median :  7.50   Median :  9.50   Median :34      
##  Mean   :  6.204   Mean   : 29.71   Mean   : 38.18   Mean   :34      
##  3rd Qu.:  7.750   3rd Qu.: 19.25   3rd Qu.: 23.50   3rd Qu.:34      
##  Max.   :379.000   Max.   :380.00   Max.   :382.00   Max.   :34      
##  NA's   :6         NA's   :360      NA's   :360      NA's   :387     
##  admittoicudc3
##  Min.   :35   
##  1st Qu.:35   
##  Median :35   
##  Mean   :35   
##  3rd Qu.:35   
##  Max.   :35   
##  NA's   :387

3.8 Mechanical Ventilation

knitr::kable(subset(pedalfast_metadata, variable %in% c("ventyn", "admittoint", "admittoext")))
variable description values
43 ventyn Did the patient receive invasive Mechanical Ventilation during this admission? 0, no | 1, yes
44 admittoint Days from admit to intubation integer (days)
45 admittoext Days from admit to extubation integer (days)
summary(pedalfast[, c("ventyn", "admittoint", "admittoext")])
##      ventyn         admittoint       admittoext    
##  Min.   :0.0000   Min.   :-2.000   Min.   :-2.000  
##  1st Qu.:1.0000   1st Qu.: 0.000   1st Qu.: 0.000  
##  Median :1.0000   Median : 0.000   Median : 0.000  
##  Mean   :0.9304   Mean   : 1.436   Mean   : 2.415  
##  3rd Qu.:1.0000   3rd Qu.: 1.000   3rd Qu.: 3.000  
##  Max.   :1.0000   Max.   :32.000   Max.   :64.000  
##                   NA's   :51       NA's   :34

3.9 Intracranial pressure (ICP) monitors

knitr::kable(subset(pedalfast_metadata, grepl("^(admitto)*icp.+\\d", variable)))
variable description values
46 icpyn1 Did the patient receive an ICP Monitor? 0, no | 1, yes
47 icptype1 First ICP monitor type NA
48 icptype2 Second ICP monitor type NA
49 icptype3 Third ICP monitor type NA
50 admittoicpstart1 Days from admission to first ICP monitor integer (days)
51 admittoicpstart2 Days from admission to second ICP monitor integer (days)
52 admittoicpstart3 Days from admission to third ICP monitor integer (days)
53 admittoicpend1 Days from admission to removal of first ICP monitor integer (days)
54 admittoicpend2 Days from admission to removal of second ICP monitor integer (days)
55 admittoicpend3 Days from admission to removal of third ICP monitor integer (days)
summary(pedalfast[pedalfast$icpyn1 == 1, grepl("^(admitto)*icp.+\\d", names(pedalfast))])
##      icpyn1    icptype1           icptype2           icptype3        
##  Min.   :1   Length:131         Length:131         Length:131        
##  1st Qu.:1   Class :character   Class :character   Class :character  
##  Median :1   Mode  :character   Mode  :character   Mode  :character  
##  Mean   :1                                                           
##  3rd Qu.:1                                                           
##  Max.   :1                                                           
##  NA's   :1                                                           
##  admittoicpstart1 admittoicpend1   admittoicpstart2 admittoicpend2 
##  Min.   :-1.000   Min.   : 0.000   Min.   :-1.000   Min.   : 1.00  
##  1st Qu.: 0.000   1st Qu.: 2.250   1st Qu.: 0.250   1st Qu.: 9.00  
##  Median : 0.000   Median : 4.000   Median : 1.500   Median :11.00  
##  Mean   : 1.454   Mean   : 5.844   Mean   : 4.462   Mean   :14.52  
##  3rd Qu.: 1.000   3rd Qu.: 7.000   3rd Qu.: 4.000   3rd Qu.:14.00  
##  Max.   :91.000   Max.   :68.000   Max.   :57.000   Max.   :71.00  
##  NA's   :1        NA's   :9        NA's   :105      NA's   :106    
##  admittoicpstart3 admittoicpend3
##  Min.   : 1.00    Min.   :7     
##  1st Qu.:24.75    1st Qu.:7     
##  Median :48.50    Median :7     
##  Mean   :48.50    Mean   :7     
##  3rd Qu.:72.25    3rd Qu.:7     
##  Max.   :96.00    Max.   :7     
##  NA's   :129      NA's   :130

ICP monitor types:

table(pedalfast$icptype1)
## 
##                   Intraparenchymal (Camino or bolt) 
##                                                  92 
##                                               Other 
##                                                   8 
## Ventriculostomy (External Ventricular Drain or EVD) 
##                                                  27

3.10 Invasive Vascular Catheters

knitr::kable(subset(pedalfast_metadata, grepl("^(admitto)*cath.+\\d", variable)))
variable description values
56 cathtype1 Type of first invasive vascular catheter NA
57 cathtype2 Type of second invasive vascular catheter NA
58 cathtype3 Type of third invasive vascular catheter NA
59 cathtype4 Type of fourth invasive vascular catheter NA
60 admittocathstart1 Days from admission to first catheter integer (days)
61 admittocathstart2 Days from admission to second catheter integer (days)
62 admittocathstart3 Days from admission to third catheter integer (days)
63 admittocathstart4 Days from admission to fourth catheter integer (days)
64 admittocathend1 Days from admission to removal of first catheter integer (days)
65 admittocathend2 Days from admission to removal of second catheter integer (days)
66 admittocathend3 Days from admission to removal of third catheter integer (days)
67 admittocathend4 Days from admission to removal of fourth catheter integer (days)

First catheter

summary(
  subset(pedalfast,
         !is.na(cathtype1),
         select = grep("cath.*1$", names(pedalfast)))
)
##   cathtype1         admittocathstart1 admittocathend1  
##  Length:243         Min.   :-2.0000   Min.   : -1.000  
##  Class :character   1st Qu.: 0.0000   1st Qu.:  2.000  
##  Mode  :character   Median : 0.0000   Median :  4.000  
##                     Mean   : 0.4033   Mean   :  6.415  
##                     3rd Qu.: 1.0000   3rd Qu.:  7.000  
##                     Max.   : 6.0000   Max.   :368.000  
##                                       NA's   :24
table(pedalfast$cathtype1)
## 
##                             Arterial catheter 
##                                           112 
##                       Central venous catheter 
##                                           115 
## Peripherally inserted central catheter (PICC) 
##                                            16

Second catheter

summary(
  subset(pedalfast,
         !is.na(cathtype2),
         select = grep("cath.*2$", names(pedalfast)))
)
##   cathtype2         admittocathstart2 admittocathend2  
##  Length:166         Min.   :-1.000    Min.   :-59.000  
##  Class :character   1st Qu.: 0.000    1st Qu.:  3.000  
##  Mode  :character   Median : 0.000    Median :  6.000  
##                     Mean   : 1.018    Mean   :  6.622  
##                     3rd Qu.: 1.000    3rd Qu.:  9.000  
##                     Max.   :31.000    Max.   : 93.000  
##                                       NA's   :18
table(pedalfast$cathtype2)
## 
##                             Arterial catheter 
##                                            98 
##                       Central venous catheter 
##                                            52 
## Peripherally inserted central catheter (PICC) 
##                                            16

Third catheter

summary(
  subset(pedalfast,
         !is.na(cathtype3),
         select = grep("cath.*3$", names(pedalfast)))
)
##   cathtype3         admittocathstart3 admittocathend3
##  Length:56          Min.   :-1.000    Min.   : 1.00  
##  Class :character   1st Qu.: 0.250    1st Qu.: 5.75  
##  Mode  :character   Median : 2.000    Median :10.00  
##                     Mean   : 3.796    Mean   :12.62  
##                     3rd Qu.: 5.750    3rd Qu.:14.50  
##                     Max.   :19.000    Max.   :94.00  
##                     NA's   :2         NA's   :8
table(pedalfast$cathtype3)
## 
##                             Arterial catheter 
##                                            16 
##                       Central venous catheter 
##                                            12 
## Peripherally inserted central catheter (PICC) 
##                                            28

Fourth catheter

summary(
  subset(pedalfast,
         !is.na(cathtype4),
         select = grep("cath.*4$", names(pedalfast)))
)
##   cathtype4         admittocathstart4 admittocathend4
##  Length:15          Min.   : 0.000    Min.   : 2.00  
##  Class :character   1st Qu.: 2.000    1st Qu.: 8.00  
##  Mode  :character   Median : 5.000    Median :20.00  
##                     Mean   : 9.333    Mean   :22.93  
##                     3rd Qu.: 9.000    3rd Qu.:36.00  
##                     Max.   :37.000    Max.   :57.00
table(pedalfast$cathtype4)
## 
##                             Arterial catheter 
##                                             4 
##                       Central venous catheter 
##                                             3 
## Peripherally inserted central catheter (PICC) 
##                                             8

3.11 Tracheostomy

knitr::kable(subset(pedalfast_metadata, variable %in% c("newtrachyn", "admittotrach")))
variable description values
68 newtrachyn Did the patient receive a new tracheostomy? 0, no | 1, yes
69 admittotrach Days from admission to tracheostomy integer (days)
summary(pedalfast[pedalfast$newtrachyn == 1, c("newtrachyn", "admittotrach")])
##    newtrachyn  admittotrach  
##  Min.   :1    Min.   : 0.00  
##  1st Qu.:1    1st Qu.: 7.50  
##  Median :1    Median :13.00  
##  Mean   :1    Mean   :15.70  
##  3rd Qu.:1    3rd Qu.:18.75  
##  Max.   :1    Max.   :46.00

3.12 Gastrostomy

knitr::kable(subset(pedalfast_metadata, variable %in% c("newgastyn", "admittogast")))
variable description values
70 newgastyn Did the patient receive a new gastrostomy? 0, no | 1, yes
71 admittogast Days from admission to gastrostomy integer (days)
summary(pedalfast[pedalfast$newgastyn == 1, c("newgastyn", "admittogast")])
##    newgastyn  admittogast   
##  Min.   :1   Min.   : 1.00  
##  1st Qu.:1   1st Qu.:12.50  
##  Median :1   Median :21.00  
##  Mean   :1   Mean   :22.78  
##  3rd Qu.:1   3rd Qu.:33.50  
##  Max.   :1   Max.   :50.00

3.13 Decompressive craniectomy

knitr::kable(subset(pedalfast_metadata, variable %in% c("decomcranyn", "admittocrani")))
variable description values
72 decomcranyn Did the patient receive a decompressive craniectomy? 0, no | 1, yes
73 admittocrani Days from admission to decompressive craniectomy integer (days)
summary(pedalfast[pedalfast$decomcranyn == 1, c("decomcranyn", "admittocrani")])
##   decomcranyn  admittocrani    
##  Min.   :1    Min.   :-1.0000  
##  1st Qu.:1    1st Qu.: 0.0000  
##  Median :1    Median : 0.0000  
##  Mean   :1    Mean   : 0.9773  
##  3rd Qu.:1    3rd Qu.: 1.0000  
##  Max.   :1    Max.   :10.0000  
##  NA's   :4    NA's   :4

3.14 Lumbar Drain

knitr::kable(subset(pedalfast_metadata, variable %in% c("lmbrdrainyn", "admittolmbdrain")))
variable description values
74 lmbrdrainyn Did the patient receive a new lumbar drain 0, no | 1, yes
75 admittolmbdrain Days from admission to lumbar drain integer (days)
summary(pedalfast[pedalfast$lmbrdrainyn == 1, c("lmbrdrainyn", "admittolmbdrain")])
##   lmbrdrainyn admittolmbdrain
##  Min.   :1    Min.   : 2.00  
##  1st Qu.:1    1st Qu.: 2.75  
##  Median :1    Median : 4.00  
##  Mean   :1    Mean   : 7.50  
##  3rd Qu.:1    3rd Qu.: 8.75  
##  Max.   :1    Max.   :20.00

3.15 Epidural Hematoma Evacuated

knitr::kable(subset(pedalfast_metadata, variable %in% c("epihemyn", "admittoedhevac")))
variable description values
76 epihemyn Did the patient have an epidural hematoma evacuated? 0, no | 1, yes
77 admittoedhevac Days from admission to evacuation of epidural hematoma integer (days)
summary(pedalfast[pedalfast$epihemyn == 1, c("epihemyn", "admittoedhevac")])
##     epihemyn admittoedhevac   
##  Min.   :1   Min.   :-1.0000  
##  1st Qu.:1   1st Qu.: 0.0000  
##  Median :1   Median : 0.0000  
##  Mean   :1   Mean   : 0.1034  
##  3rd Qu.:1   3rd Qu.: 0.0000  
##  Max.   :1   Max.   : 1.0000

3.16 Subdural Hematoma Evacuated

knitr::kable(subset(pedalfast_metadata, variable %in% c("subhemyn", "admittosdhevac")))
variable description values
78 subhemyn Did the patient have a subdural hematoma evacuated? 0, no | 1, yes
79 admittosdhevac Days from admission to evacuation of subdural hematoma integer (days)
summary(pedalfast[pedalfast$subhemyn == 1, c("subhemyn", "admittosdhevac")])
##     subhemyn admittosdhevac   
##  Min.   :1   Min.   :-1.0000  
##  1st Qu.:1   1st Qu.: 0.0000  
##  Median :1   Median : 0.0000  
##  Mean   :1   Mean   : 0.6977  
##  3rd Qu.:1   3rd Qu.: 0.5000  
##  Max.   :1   Max.   :11.0000

3.17 Medications

knitr::kable(subset(pedalfast_metadata, grepl("^rx", variable)))
variable description values
80 rxhypsal Was hypertonic saline ordered? 0, no | 1, yes
81 rxmann Was mannitol ordered? 0, no | 1, yes
82 rxbarb Was a barbiturate ordered? 0, no | 1, yes
83 rxinotrvas Was an inotrope or vasopressor ordered? 0, no | 1, yes
summary(pedalfast[, grepl("^rx", names(pedalfast))])
##     rxhypsal          rxmann          rxbarb         rxinotrvas    
##  Min.   :0.0000   Min.   :0.000   Min.   :0.0000   Min.   :0.0000  
##  1st Qu.:0.0000   1st Qu.:0.000   1st Qu.:0.0000   1st Qu.:0.0000  
##  Median :1.0000   Median :0.000   Median :0.0000   Median :0.0000  
##  Mean   :0.5438   Mean   :0.171   Mean   :0.1068   Mean   :0.3798  
##  3rd Qu.:1.0000   3rd Qu.:0.000   3rd Qu.:0.0000   3rd Qu.:1.0000  
##  Max.   :1.0000   Max.   :1.000   Max.   :1.0000   Max.   :1.0000  
##                   NA's   :2       NA's   :4        NA's   :1

3.18 TPN

knitr::kable(subset(pedalfast_metadata, variable %in% c("tpnyn", "admittotpn")))
variable description values
84 tpnyn Did the patient receive TPN? 0, no | 1, yes
85 admittotpn Days from admission to first TPN integer (days)
summary(pedalfast[pedalfast$tpnyn == 1, c("tpnyn", "admittotpn")])
##      tpnyn     admittotpn  
##  Min.   :1   Min.   :0.00  
##  1st Qu.:1   1st Qu.:2.00  
##  Median :1   Median :2.50  
##  Mean   :1   Mean   :3.35  
##  3rd Qu.:1   3rd Qu.:5.00  
##  Max.   :1   Max.   :9.00  
##              NA's   :1

3.19 Enteral Nutrition

knitr::kable(subset(pedalfast_metadata, variable %in% c("entnutyn", "admittoentnut")))
variable description values
86 entnutyn Did the patient receive enteral nutrition? 0, no | 1, yes
87 admittoentnut Days from admission to enteral nutrition integer (days)
summary(pedalfast[pedalfast$entnutyn == 1, c("entnutyn", "admittoentnut")])
##     entnutyn admittoentnut     
##  Min.   :1   Min.   :   0.000  
##  1st Qu.:1   1st Qu.:   1.000  
##  Median :1   Median :   2.000  
##  Mean   :1   Mean   :   5.973  
##  3rd Qu.:1   3rd Qu.:   2.000  
##  Max.   :1   Max.   :1098.000

3.20 Hospital LOS and Disposition

knitr::kable(subset(pedalfast_metadata, variable %in% c("hosplos", "hospdisposition")))
variable description values
88 hosplos Hospital length of stay (days) integer (days)
89 hospdisposition Where did the patient go when they were discharged from the hospital? character
summary(pedalfast[, c("hosplos", "hospdisposition")])
##     hosplos       hospdisposition   
##  Min.   :  0.00   Length:388        
##  1st Qu.:  4.00   Class :character  
##  Median :  9.00   Mode  :character  
##  Mean   : 16.42                     
##  3rd Qu.: 20.00                     
##  Max.   :345.00
table(pedalfast$hospdisposition, useNA = "always")
## 
## Discharge TO or WITH Hospice    Home with Skilled Nursing 
##                            1                            7 
##        Home, no new supports              Inpatient Rehab 
##                          236                           62 
##                    Mortality                        Other 
##                           65                           16 
##  Short-term Nursing Facility                         <NA> 
##                            1                            0

3.21 Cardiac Arrest

Indicator and location for cardiac arrest.

knitr::kable(subset(pedalfast_metadata, grepl("^cardiac", variable)))
variable description values
90 cardiacarrestyn Did the patient have a cardiac arrest at any time from the time of injury to the time of hospital discharge? 0, no | 1, yes
91 cardiacarrestprehosp Cardiac arrest pre hospital 0, no | 1, yes
92 cardiacarrested Cardiac arrest emergency department 0, no | 1, yes
93 cardiacarrestor Cardiac arrest operating room 0, no | 1, yes
94 cardiacarrestcu Cardiac arrest ICU 0, no | 1, yes
95 cardiacarrestoter Cardiac arrest other 0, no | 1, yes
summary(pedalfast[, grepl("^cardiac", names(pedalfast))])
##  cardiacarrestyn  cardiacarrestprehosp cardiacarrested  cardiacarrestor  
##  Min.   :0.0000   Min.   :0.0000       Min.   :0.0000   Min.   :0.00000  
##  1st Qu.:0.0000   1st Qu.:0.0000       1st Qu.:0.0000   1st Qu.:0.00000  
##  Median :0.0000   Median :0.0000       Median :0.0000   Median :0.00000  
##  Mean   :0.1521   Mean   :0.1031       Mean   :0.0232   Mean   :0.01031  
##  3rd Qu.:0.0000   3rd Qu.:0.0000       3rd Qu.:0.0000   3rd Qu.:0.00000  
##  Max.   :1.0000   Max.   :1.0000       Max.   :1.0000   Max.   :1.00000  
##  cardiacarresticu  cardiacarrestother
##  Min.   :0.00000   Min.   :0.000000  
##  1st Qu.:0.00000   1st Qu.:0.000000  
##  Median :0.00000   Median :0.000000  
##  Mean   :0.04124   Mean   :0.005155  
##  3rd Qu.:0.00000   3rd Qu.:0.000000  
##  Max.   :1.00000   Max.   :1.000000

3.22 Functional Status Scale

knitr::kable(subset(pedalfast_metadata, grepl("fss", variable)))
variable description values
96 admittofss Days from admission to FSS evaluation integer (days)
97 sourcefss Source of FSS evaluation NA
98 fssmental FSS Mental Status 1, Normal sleep/wake periods; appropriate responsiveness | 2, Sleepy but arousable to noise/touch/movement and/or periods of social nonresponsiveness | 3, Lethargic and/or irritable | 4, Minimal arousal to stimuli (stupor) | 5, Unresponsive, coma, and/or vegetative state
99 fsssensory FSS Sensory 1, Intact hearing and vision and responsive to touch | 2, Suspected hearing or vision loss | 3, Not reactive to one of auditory stimuli or visual stimuli | 4, Not reactive to either auditory or visual stimuli | 5, Abnormal responses to pain or touch
100 fsscommun FSS Communication 1, Appropriate noncrying vocalizations, interactive facial expressiveness, or gestures | 2, Diminished vocalization, facial expression, and/or social responsiveness | 3, Absence of attention-getting behavior | 4, No demonstration of discomfort | 5, Absence of communication
101 fssmotor FSS Motor 1, Coordinated body movements, normal muscle control, and awareness of action and reason | 2, One limb functionally impaired | 3, Two or more limbs functionally impaired | 4, Poor head control | 5, Diffuse spasticity, paralysis, or decerebrate/decorticate posturing
102 fssfeeding FSS Feeding 1, All food taken by mouth with age-appropriate help | 2, Nothing by mouth or need for age-inappropriate help with feeding | 3, Oral and tube feedings | 4, Parenteral nutrition with oral or tube feedings | 5, All parenteral nutrition
103 fssresp FSS Respiratory 1, Room air and no artificial support or aids | 2, Oxygen treatment and/or suctioning | 3, Tracheostomy for airway | 4, Continuous positive airway pressure (CPAP/BIPAP) for all or part of the day and/