Opal Data Dictionary with R

This is an example of how to use knitr for producing a data dictionary on data stored in Opal.

The table StandingHeight is about "Participant".

It has 21 variables and 5113 entries.

Variables

InstrumentRun.user

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight

InstrumentRun.timeStart

Properties

Property Value
Entity type Participant
Value type datetime
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight

InstrumentRun.timeEnd

Properties

Property Value
Entity type Participant
Value type datetime
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight

InstrumentRun.otherContraindication

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight

InstrumentRun.instrumentBarcode

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight

InstrumentRun.Contraindication.code

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight

InstrumentRun.Contraindication.type

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
ASKED FALSE
OBSERVED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   ASKED OBSERVED     NA's 
       0        0     5113 

RES_THIRD_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit cm
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
label [en] Optional Stadiometre reading (3)
label [fr] Lecture optionnelle du stadiomètre (3)
validation [IntegrityCheck-ERROR[MALE[70.0 < x < 210.0], FEMALE[70.0 < x < 210.0]], IntegrityCheck-WARNING[MALE[148.0 < x < 192.0], FEMALE[148.0 < x < 192.0]]]
condition Computing[1 > 2100.0]
captureMethod MANUAL

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
     NA      NA      NA     NaN      NA      NA    5113 

CALC_ABS_DIFF_FIRST_AND_SECOND_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
        0         0      1621      3492 

plot of chunk unnamed-chunk-81

CALC_ABS_DIFF_FIRST_AND_THIRD_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
source Computing[Abs[$1 - $2],[Instrument[StandingHeight, RES_FIRST_HEIGHT], Instrument[StandingHeight, RES_THIRD_HEIGHT]]]
captureMethod COMPUTED

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
    143     162     168     169     175     201    3492 

plot of chunk unnamed-chunk-89

RES_SEC_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit cm
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
label [en] Optional Stadiometre reading (2)
label [fr] Lecture optionnelle du stadiomètre (2)
validation [IntegrityCheck-ERROR[MALE[70.0 < x < 210.0], FEMALE[70.0 < x < 210.0]], IntegrityCheck-WARNING[MALE[148.0 < x < 192.0], FEMALE[148.0 < x < 192.0]]]
condition Computing[1 > 2100.0]
captureMethod MANUAL

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
    161     169     178     178     187     196    5111 

plot of chunk unnamed-chunk-98

RES_FIRST_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit cm
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
label [en] Stadiometre reading (1)
label [fr] Lecture du stadiomètre (1)
validation [IntegrityCheck-ERROR[MALE[70.0 < x < 210.0], FEMALE[70.0 < x < 210.0]], IntegrityCheck-WARNING[MALE[148.0 < x < 192.0], FEMALE[148.0 < x < 192.0]]]
captureMethod MANUAL

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
    143     162     168     169     175     201    3492 

plot of chunk unnamed-chunk-107

RES_FIRST_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
     1621         0         0      3492 

plot of chunk unnamed-chunk-117

CALC_ABS_DIFF_FIRST_AND_THIRD_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
        0         0      1621      3492 

plot of chunk unnamed-chunk-126

RES_SEC_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
     1621         0         0      3492 

plot of chunk unnamed-chunk-135

CALC_AVG_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
        0         0      1621      3492 

plot of chunk unnamed-chunk-144

CALC_ABS_DIFF_SECOND_AND_THIRD_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
source Computing[Abs[$1 - $2],[Instrument[StandingHeight, RES_SEC_HEIGHT], Instrument[StandingHeight, RES_THIRD_HEIGHT]]]
captureMethod COMPUTED

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
      0       0       0       0       0     196    3492 

plot of chunk unnamed-chunk-152

CALC_ABS_DIFF_SECOND_AND_THIRD_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
        0         0      1621      3492 

plot of chunk unnamed-chunk-162

CALC_ABS_DIFF_FIRST_AND_SECOND_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
source Computing[Abs[$1 - $2],[Instrument[StandingHeight, RES_FIRST_HEIGHT], Instrument[StandingHeight, RES_SEC_HEIGHT]]]
captureMethod COMPUTED

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
      0     162     168     168     175     201    3492 

plot of chunk unnamed-chunk-170

CALC_AVG_HEIGHT

Properties

Property Value
Entity type Participant
Value type decimal
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Attributes

Name Value
stage StandingHeight
label [en] Average Standing Height
label [fr] Hauteur debout moyenne
source Computing[If[ And[Equal[$2,0],Equal[$3,0]], $1, If[ Or[Equal[$2,0],Equal[$3,0]], If[ Equal[$2,0], Round[1, ($1 + $3)/2], Round[1, ($1 + $2)/2] ], If[ And[Less[$4, $5], Less[$4, $6]], Round[1, ($1 + $2)/2], If[ And[Less[$5, $4], Less[$5, $6]], Round[1,($1 + $3)/2], Round[1,($2 + $3)/2] ] ] ] ],[Instrument[StandingHeight, RES_FIRST_HEIGHT], Instrument[StandingHeight, RES_SEC_HEIGHT], Instrument[StandingHeight, RES_THIRD_HEIGHT], Instrument[StandingHeight, CALC_ABS_DIFF_FIRST_AND_SECOND_HEIGHT], Instrument[StandingHeight, CALC_ABS_DIFF_FIRST_AND_THIRD_HEIGHT], Instrument[StandingHeight, CALC_ABS_DIFF_SECOND_AND_THIRD_HEIGHT]]]
captureMethod COMPUTED

Descriptive Statistics

   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
    143     162     168     169     175     201    3492 

plot of chunk unnamed-chunk-179

RES_THIRD_HEIGHT.captureMethod

Properties

Property Value
Entity type Participant
Value type text
Unit
Mime Type
Repeatable FALSE
Occurrence Group

Categories

Name Label Missing
MANUAL FALSE
AUTOMATIC FALSE
COMPUTED FALSE

Attributes

Name Value
stage StandingHeight

Descriptive Statistics

   MANUAL AUTOMATIC  COMPUTED      NA's 
     1621         0         0      3492 

plot of chunk unnamed-chunk-189