-
Notifications
You must be signed in to change notification settings - Fork 4
KCE/download_gnomad_from_api #43
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
Merged
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
929d137
implemented a method request gene information by its id, forms it to …
KajusC ea192ee
dynamically adds variation properties
KajusC 6dba6fe
Implemented a function which extracts variation ids from gene name, t…
KajusC 35f43bf
Reformatted the parse
KajusC 5243f8e
Created a function which collects EYS data from gnomAD api.
KajusC 5c30ce1
Added ability to get any gene from API
KajusC 197864c
Removed from last branch
KajusC 5a23fea
Merge branch 'main' into KCE/GnomAD_api_requests
KajusC 4d3575a
Downloaded data from API, formatted code
KajusC 437954a
Refactored and resolved PR comments
KajusC 522cf70
Extra PR refactoring
KajusC File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
""" | ||
Package for data collection purposes provides both collection and refactoring functionality. | ||
|
||
Data from LOVD, ClinVar and GnomAd databases can be downloaded using this package. GnomAd and | ||
ClinVar are limited with EYS gene, but it is possible to download data for any gene in LOVD. | ||
|
||
All necessary functionality can be imported directly from data without | ||
specifying the module. | ||
|
||
data collection pipeline example is established for project's specific usage. | ||
""" | ||
|
||
# CONSTANTS IMPORT | ||
from .constants import ( | ||
# URLs for LOVD database | ||
LOVD_URL, LOVD_URL_EYS, LOVD_FILE_URL, LOVD_FILE_URL_EYS, | ||
|
||
# URLs for gnomAD database | ||
GNOMAD_URL, GNOMAD_URL_EYS, GNOMAD_FILE_URL_EYS, | ||
|
||
# URLs for ClinVar database | ||
CLINVAR_URL, CLINVAR_URL_EYS, CLINVAR_FILE_URL_EYS, | ||
|
||
# Paths for data storage | ||
DATA_PATH, LOVD_PATH, GNOMAD_PATH, CLINVAR_PATH, | ||
|
||
# Data types for tables | ||
LOVD_TABLES_DATA_TYPES, | ||
|
||
# Paths for database downloads | ||
DATABASES_DOWNLOAD_PATHS, | ||
|
||
GNOMAD_PATH, | ||
) | ||
|
||
# DATA COLLECTION IMPORT | ||
from .collection import ( | ||
# Custom exceptions | ||
BadResponseException, | ||
DownloadError, | ||
|
||
# Custom utility functions | ||
get_file_from_url, | ||
|
||
# Functions for downloading databases | ||
download_lovd_database_for_eys_gene, | ||
download_genes_lovd, | ||
download_database_for_eys_gene, | ||
|
||
# Functions for storing databases | ||
store_database_for_eys_gene | ||
) | ||
|
||
# DATA REFACTORING IMPORT | ||
from .refactoring import ( | ||
# Functions for refactoring data | ||
set_lovd_dtypes, | ||
parse_lovd, | ||
from_clinvar_name_to_cdna_position, | ||
save_lovd_as_vcf, | ||
request_gnomad_api_data, | ||
merge_gnomad_lovd, | ||
parse_gnomad, | ||
set_gnomad_dtypes, | ||
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.