Skip to content

Instantly share code, notes, and snippets.

@anthony-cros
Created December 20, 2017 10:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anthony-cros/f3e90864e9fd9ce7045b3160833fe2c9 to your computer and use it in GitHub Desktop.
Save anthony-cros/f3e90864e9fd9ce7045b3160833fe2c9 to your computer and use it in GitHub Desktop.
# notes:
# - use 4 spaces for display tab
# - repeated tabs get trimmed to one
# - anything beyond ' #' is trimmed (including marker), so are empty lines (post line-trim)
# - \N stand for no value (eg NULL in SQL)
# - PATID, ENCOUTERID and other IDs are inferred from the _id field, including redundant fields
===========================================================================
DEMOGRAPHIC
_id BIRTH_DATE SEXUAL_ORIENTATION GENDER_IDENTITY SEX HISPANIC RACE BIOBANK_FLAT
------------------------------------------------------------------------------------------------------------
01 2010-01-01 AS M A Y 01 N
02 2010-01-02 AS F F N 02 Y
03 2010-01-03 BI TM M R 03 Y
04 2010-01-04 BI TF NI NI 04 Y
05 2010-01-05 GA CQ UN UN 05 N
06 2010-01-06 GA SE OT OT 06 Y
07 2010-01-07 LE MU A UN 07 Y
08 2010-01-08 LE DC F NI NI N
===========================================================================
ENCOUNTER
_id # ADMIT_DATE DISCHARGE_DATE PROVIDERID FACILITY_LOCATION ENC_TYPE FACILITYID
----------------------------------------------------------------------------------------------------------
01-01 # 2010-02-01 2010-12-01 999999 333 AV 33
01-02 # 2010-03-01 2010-12-01 999999 333 ED 33
02-01 # 2010-02-02 2010-12-02 999998 333 EI 33
03-01 # 2010-02-03 2010-12-03 999998 334 IP 33
04-01 # 2010-02-04 2010-12-04 999997 334 IS 33
05-01 # 2010-02-05 2010-12-05 999997 334 OS 33
06-01 # 2010-02-06 2010-12-06 999996 335 IC 33
07-01 # 2010-02-07 2010-12-07 999996 335 OA 33
08-01 # 2010-02-08 2010-12-08 999995 335 NI 33
===========================================================================
DIAGNOSIS
_id DX DX_SOURCE DX_TYPE
---------------------------------------------------
01-01-01 G25.3 AD 09
01-01-02 Z00.129 AD 10
01-02-01 799.82 DI 10
02-01-01 71677004 FI 11
03-01-01 B34.9 IN SM
04-01-01 Z00.129 NI NI
05-01-01 G40.409 UN UN
06-01-01 G25.3 OT OT
06-02-01 R56.9 AD 09
===========================================================================
LAB_RESULT_CM
_id SPECIMEN_SOURCE
-------------------------------
01-01-01 BLOOD
01-02-01 CSF
01-02-02 PLASMA
02-01-01 SERUM
03-01-01 SR_PLS
===========================================================================
PRESCRIBING
_id RAW_RX_MED_NAME
---------------------------------
01-01-01 paracetamol 1000G
01-01-02 ibuprofen 1000G
01-02-01 paracetamol 500G
07-01-01 ibuprofen 500G
08-01-01 paracetamol 1000G
===========================================================================
PROCEDURES
_id PX PX_DATE PX_TYPE
---------------------------------------------------
01-01-01 82948 2012-01-01 C4
01-01-02 90680 2012-01-01 OT
01-02-01 82948 2012-01-01 C4
07-01-01 90670 2012-01-01 OT
08-01-01 90680 2012-01-01 C4
===========================================================================
VITAL
_id HT
---------------------
01-01-01 40.01
02-01-01 40.02
04-01-01 40.04
06-01-01 40.06
===========================================================================
DEATH
_id DEATH_DATE DEATH_SOURCE
----------------------------------------
01 2011-01-01 L
07 2011-01-08 N
===========================================================================
genomic_metadata
_id wgs ubam_file_exists .xml_file_exists snp_array genomic_panel fastq_file_exists wes bam_file_exists gvcf_file_exists .idat_file_exists vcf_file_exists platform
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
01 true true false true true false true true false false true Affymetrix 6208
02 true true true false true false true true false true true Affymetrix 6208
03 false true false true false true true false true false false Affymetrix 6208
04 true false true true true true true true false false false Affymetrix 6208
05 false true false true false false true true true true true Affymetrix 6208
06 false true false true false false true true true true true Affymetrix 6208
07 false true false true false false true true true true true Affymetrix 6208
08 false true false true false false true true true true true Affymetrix 6208
===========================================================================
sample_metadata
_id sample_exists tissue_type sample_type
-----------------------------------------------------------
01 true Bone/Vertebrae Whole Blood
02 true Bone/Vertebrae Whole Blood
03 false \N \N
04 false \N \N
05 false \N \N
06 false \N \N
07 false \N \N
08 false \N \N
===========================================================================
misc
_id grin_consent irb_share_forprofit irb_ror subject_primary_language institution_name irb_recontact irb_share_identified_data
---------------------------------------------------------------------------------------------------------------------------------------------------------
01 true true true English CHOP false false
02 true false true French CHOP false false
03 true false true Spanish CHOP true false
04 true false true Simlish CHOP false false
05 true false false Klingon CHOP false true
06 true false false Esperanto CHOP false true
07 true false false Javanais CHOP false true
08 false false false Pig Latin CHOP false true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment