Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change 'MAPPED TRAIT' and 'MAPPED TRAIT URI' to match published studies #162

Merged
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
12 changes: 6 additions & 6 deletions dataExport/unpublish_study_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ def build_studies_download(url, outputdir):
with open(outputdir + '/gwas-catalog-unpublished-studies-v1.0.3.tmp.tsv', 'w', newline='') as csvfile:
fieldnames = ['DATE ADDED TO CATALOG', 'PUBMED ID', 'FIRST AUTHOR', 'DATE', 'JOURNAL', 'LINK', 'STUDY',
'DISEASE/TRAIT', 'INITIAL SAMPLE SIZE', 'REPLICATION SAMPLE SIZE',
'PLATFORM [SNPS PASSING QC]', 'ASSOCIATION COUNT', 'MAPPED TRAIT', 'MAPPED TRAIT URI',
'PLATFORM [SNPS PASSING QC]', 'ASSOCIATION COUNT', 'MAPPED_TRAIT', 'MAPPED_TRAIT_URI',
'STUDY ACCESSION', 'GENOTYPING TECHNOLOGY', 'SUMMARY STATS LOCATION', 'SUBMISSION DATE',
'STATISTICAL MODEL', 'BACKGROUND TRAIT', 'MAPPED BACKGROUND TRAIT',
'MAPPED BACKGROUND TRAIT URI']
Expand All @@ -124,8 +124,8 @@ def build_studies_download(url, outputdir):
table['REPLICATION SAMPLE SIZE'] = 'not yet curated'
table['PLATFORM [SNPS PASSING QC]'] = (study['array_manufacturer'] or 'NR') + ' [' + str(study['variant_count'] or 'NR') + ']'
table['ASSOCIATION COUNT'] = 'not yet curated'
table['MAPPED TRAIT'] = 'not yet curated'
table['MAPPED TRAIT URI'] = 'not yet curated'
table['MAPPED_TRAIT'] = 'not yet curated'
table['MAPPED_TRAIT_URI'] = 'not yet curated'
table['STUDY ACCESSION'] = study['study_accession']
table['GENOTYPING TECHNOLOGY'] = study['genotyping_technology']
table['SUMMARY STATS LOCATION'] = generate_sumstats_ftp_path(study['study_accession'])
Expand All @@ -150,7 +150,7 @@ def build_studies_download_new(url, outputdir):
with open(outputdir + '/gwas-catalog-unpublished-studies-v1.0.3.1.tmp.tsv', 'w', newline='') as csvfile:
fieldnames = ['DATE ADDED TO CATALOG', 'PUBMED ID', 'FIRST AUTHOR', 'DATE', 'JOURNAL', 'LINK', 'STUDY',
'DISEASE/TRAIT', 'INITIAL SAMPLE SIZE', 'REPLICATION SAMPLE SIZE',
'PLATFORM [SNPS PASSING QC]', 'ASSOCIATION COUNT', 'MAPPED TRAIT', 'MAPPED TRAIT URI',
'PLATFORM [SNPS PASSING QC]', 'ASSOCIATION COUNT', 'MAPPED_TRAIT', 'MAPPED_TRAIT_URI',
'STUDY ACCESSION', 'GENOTYPING TECHNOLOGY', 'SUBMISSION DATE',
'STATISTICAL MODEL', 'BACKGROUND TRAIT', 'MAPPED BACKGROUND TRAIT','MAPPED BACKGROUND TRAIT URI',
'COHORT', 'FULL SUMMARY STATISTICS', 'SUMMARY STATS LOCATION']
Expand All @@ -166,8 +166,8 @@ def build_studies_download_new(url, outputdir):
table['REPLICATION SAMPLE SIZE'] = 'not yet curated'
table['PLATFORM [SNPS PASSING QC]'] = (study['array_manufacturer'] or 'NR') + ' [' + str(study['variant_count'] or 'NR') + ']'
table['ASSOCIATION COUNT'] = 'not yet curated'
table['MAPPED TRAIT'] = 'not yet curated'
table['MAPPED TRAIT URI'] = 'not yet curated'
table['MAPPED_TRAIT'] = 'not yet curated'
table['MAPPED_TRAIT_URI'] = 'not yet curated'
table['STUDY ACCESSION'] = study['study_accession']
table['GENOTYPING TECHNOLOGY'] = study['genotyping_technology']
table['SUBMISSION DATE'] = datetime.date.fromtimestamp(study['createdDate'] / 1000).isoformat()
Expand Down