Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gdcdictionary/schema_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

def load_yaml_schema(path):
with open(path, 'r') as f:
return yaml.load(f)
return yaml.load(f, Loader=yaml.FullLoader)
CUR_DIR = os.path.dirname(os.path.realpath(__file__))
DATA_DIR = os.path.join(CUR_DIR, 'examples')
project1 = load_yaml_schema(os.path.join(CUR_DIR, 'schemas/projects/project1.yaml'))
Expand Down
32 changes: 15 additions & 17 deletions gdcdictionary/schemas/demographic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ id: "demographic"
title: Demographic
type: object
nodeTerms: null
namespace: https://nci-crdc-demo.datacommons.io/
namespace: https://elwazi-demo.planx-pla.net/
category: clinical
program: '*'
project: '*'
Expand Down Expand Up @@ -42,26 +42,14 @@ properties:

$ref: "_definitions.yaml#/ubiquitous_properties"

age_range:
age:
description: Range of ages for the subject. The age range should not include ages
over 89 years.
type: string

cause_of_death:
description: Text term to identify the cause of death for a patient.
type: string

days_to_birth:
description: Time interval from a person’s date of birth to the date of initial
pathologic diagnosis, represented as a calculated negative number of days.
type: integer
maximum: 0
minimum: -32872

days_to_death:
description: Time interval from a person’s date of death to the date of initial
pathologic diagnosis, represented as a calculated number of days.
type: integer
bmi:
description: Subject Body Mass Index (kg/m^2)
type: number

ethnicity:
term:
Expand All @@ -83,6 +71,16 @@ properties:
- unknown
- unspecified

marital_status:
description: current relationship status of subject
enum:
- No regular partner
- Separated
- Primary regular partner
- Widowed
- Married
- Unknown

race:
term:
$ref: "_terms.yaml#/race"
Expand Down
93 changes: 93 additions & 0 deletions gdcdictionary/schemas/exposure.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
$schema: "http://json-schema.org/draft-04/schema#"

id: "exposure"
title: Envorinmental Exposure
type: object
nodeTerms: null
namespace: https://elwazi-demo.planx-pla.net/
category: clinical
program: '*'
project: '*'
description: Environmental factors that the patient has been exposed to that contribute to current diagnosis
additionalProperties: false
submittable: true
validators: null

systemProperties:
- id
- project_id
- state
- created_datetime
- updated_datetime

links:
- name: subjects
backref: exposures
label: describes
target_type: subject
multiplicity: many_to_one
required: true

required:
- submitter_id
- type
- subjects

uniqueKeys:
- [id]
- [project_id, submitter_id]

properties:

$ref: "_definitions.yaml#/ubiquitous_properties"

contraceptive:
description: type of contraception used
enum:
- Condoms
- Hysterectomy
- Implant
- Injectable
- IUCD
- Oral
- Tubal ligation
- unknown
E
electricity:
description: Electricity at residence
type: string

sexual_intercourse:
decsription: Sexual intercourse in the past three months
type: string

tap_water:
description: Tap Water at residence
type: string

travel_time:
desription: travel time from residence to clinic
enum:
- Less than 30 minutes
- 30-60 minutes
- 1-2 hours
- Greater than 2 hours
- unknown

use_condom:
description: Frequency of condom use
enum:
- Always
- Sometimes
- Never
- unknown

use_familyplanning
description: Use family planning methods
enum:
- Yes
- No
- unknown

subjects:
$ref: "_definitions.yaml#/to_one"
182 changes: 182 additions & 0 deletions gdcdictionary/schemas/medical_history.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,182 @@
$schema: "http://json-schema.org/draft-04/schema#"

id: "medical_history"
title: Medical_history
type: object
nodeTerms: null
namespace: https://elwazi-demo.planx-pla.net/
category: clinical
program: '*'
project: '*'
description: Data obtained from the patient about past conditions
additionalProperties: false
submittable: true
validators: null

systemProperties:
- id
- project_id
- state
- created_datetime
- updated_datetime

links:
- name: subjects
backref: demographics
label: describes
target_type: subject
multiplicity: one_to_one
required: true

required:
- submitter_id
- type
- subjects

uniqueKeys:
- [id]
- [project_id, submitter_id]

properties:

$ref: "_definitions.yaml#/ubiquitous_properties"

arv_treatment:
description: subject currently taking antiretroviral arv_treatment
enum:
- Yes
- No
- unknown

additional_children:
description: Does subject want additional children
enum:
- Yes
- No
- Not sure
- unknown

breastfeeding:
description: Is Subject current breastfeeding
enum:
- Yes
- No
- unknown

cd4_count:
description: CD4 Lymphocyte cd4_count
type: number

cough:
description: patient reports cough for more than two weeks
enum:
- Yes
- No
- unknown

fever:
description: patient reports fever for more than two weeks
enum:
- Yes
- No
- unknown

HIV_treatment_regimen:
description: ARV regiment or line of arv_treatment
enum:
- EFV based
- Lpv/r
- ATV/r
- RTV based
- other
- unknown

lost_weight:
description: patient reports weight loss in past month
enum:
- Yes
- No
- unknown

night_sweats:
description: patient reports experiencing night sweats
enum:
- Yes
- No
- unknown

number_children_choice:
description: number of children subject would to have alive
type: integer

pregnancy_desire:
description: Does subject want to become pregnant ever
enum:
- Yes
- No
- unknown

tb_treament:
description: Received treatment for TB in last three months
enum:
- Yes
- No
- unknown

tell_partner_HIV_status:
description: Did subject inform partner of HIV hpv_status
enum:
- Yes
- No
- unknown

new_pregnancy:
description: New pregnancy at followup
type: string

new_pregnancy_outcome:
description: Outcome of new pregnancy
enum:
- Abortion/miscarriage < 20 weeks
- Congenital anomalies
- Live birth
- Low birth weight <2500g
- Preterm delivery <37 weeks
- Stillbirth/intrauterine fetal death >20 weeks
- unknown

number_additional_children:
description: How many more children would subject like to have
type: integer


test_partner_hiv_stat:
description: Does subject know if partner tested for hiv_positive
enum:
- Yes
- No
- unknown


total_pregnancies:
description: Total number of pregnancies reported by subjects
type: integer

viral_load:
description: HIV viral load from blood specimen
enum:
- <200 cp/ml
- >1000 cp/ml
- 200-399 cp/ml
- 400-1000 cp/ml
- Undetectable
- unknown

who_clinical_classification:
description: WHO clinical classification of HIV status 1 - Asymptomatic, 2 - symptomatic 3 -
enum:
- 1
- 2
- 3
- 4
- unknown
32 changes: 1 addition & 31 deletions gdcdictionary/schemas/study.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ id: "study"
title: Study
type: object
nodeTerms: null
namespace: https://nci-crdc-demo.datacommons.io/
namespace: https://elwazi-demo.planx-pla.net/
category: administrative
program: '*'
project: '*'
Expand Down Expand Up @@ -43,41 +43,11 @@ properties:

$ref: "_definitions.yaml#/ubiquitous_properties"

analytical_fraction:
description: Type of peptide or protein enrichment
type: string

data_description:
description: Brief description of the data being provided for this study. Free
text
type: string

experiment_type:
description: General strategy used for differential analysis
type: string

is_clinical_trial:
description: Flag that indicates whether this is a clinical trial study
type: boolean

study_completeness:
description: Description of data status. 0=Descriptive data and results as originally
received from the data provider. 1=Includes updates to the original data submission
short of completeness. 2=Complete set of descriptive data and results, as ascertained
by curator.
enum:
- '0'
- '1'
- '2'

study_description:
description: A brief description of the study being performed. Free text
type: string

study_design:
description: Summary of the goals the study is designed to discover. General description
of the study's place in relation to a clinical application.
type: string

study_doi:
description: Digital object identifier (DOI) is a type of persistent identifier
Expand Down
Loading