Skip to content

Commit

Permalink
updated VEP pick csq criteria
Browse files Browse the repository at this point in the history
  • Loading branch information
sigven committed Dec 15, 2023
1 parent f2f8e12 commit c809907
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
13 changes: 8 additions & 5 deletions pcgr/arg_checker.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,16 +187,19 @@ def check_args(arg_dict):
# Check that VEP pick criteria is formatted correctly
if not arg_dict['vep_pick_order'] is None:
values = str(arg_dict['vep_pick_order']).split(',')
permitted_sources = ['canonical', 'appris', 'tsl', 'biotype', 'ccds', 'rank', 'length', 'mane_select','mane_plus_clinical']
permitted_sources = pcgr_vars.VEP_PICK_CRITERIA
num_permitted_sources = 0
for v in values:
if v in permitted_sources:
num_permitted_sources += 1

if num_permitted_sources != 9:
err_msg = (f"'--vep_pick_order' = {arg_dict['vep_pick_order']} is formatted incorrectly, should be "
"a comma-separated string of the following values: mane_select,mane_plus_clinical,canonical,appris,tsl,biotype,ccds,rank,length")
if num_permitted_sources != len(pcgr_vars.VEP_PICK_CRITERIA):
err_msg = (
f"Option '--vep_pick_order' = {str(arg_dict['vep_pick_order'])} is formatted incorrectly, should be "
f"a comma-separated string of the following values: '{' '.join(pcgr_vars.VEP_PICK_CRITERIA)}'"
)
error_message(err_msg, logger)

return


Expand Down Expand Up @@ -513,7 +516,7 @@ def check_args_cpsr(arg_dict):
if v in permitted_sources:
num_permitted_sources += 1

if num_permitted_sources != 8:
if num_permitted_sources != len(pcgr_vars.VEP_PICK_CRITERIA):
err_msg = (
f"Option '--vep_pick_order' = {str(arg_dict['vep_pick_order'])} is formatted incorrectly, should be "
f"a comma-separated string of the following values: '{' '.join(pcgr_vars.VEP_PICK_CRITERIA)}'"
Expand Down
6 changes: 3 additions & 3 deletions pcgr/cpsr.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ def get_args():
optional_other.add_argument('--version', action='version', version=str(utils.get_cpsr_version()))
optional_other.add_argument('--no_reporting',action="store_true",help="Run functional variant annotation on VCF through VEP/vcfanno, omit classification/report generation (STEP 4), default: %(default)s")
optional_other.add_argument('--retained_info_tags', dest ='retained_info_tags', default='None', help='Comma-separated string of VCF INFO tags from query VCF that should be kept in CPSR output TSV')
optional_other.add_argument('--report_theme',choices = ['default','cerulean','journal','flatly','readable','spacelab','united','cosmo','lumen','paper','sandstone','simplex','yeti'], default = 'default', help='Visual report theme (rmarkdown), default: %(default)s' )
optional_other.add_argument('--report_nonfloating_toc', action='store_true', help='Do not float the table of contents (TOC) in output HTML report, default: %(default)s')
optional_other.add_argument('--report_table_display', choices = ['full','light'], default='light', help="Set the level of detail/comprehensiveness in interactive datables of HTML report, very comprehensive (option 'full') or slim/focused ('light'), default: %(default)s")
#optional_other.add_argument('--report_theme',choices = ['default','cerulean','journal','flatly','readable','spacelab','united','cosmo','lumen','paper','sandstone','simplex','yeti'], default = 'default', help='Visual report theme (rmarkdown), default: %(default)s' )
#optional_other.add_argument('--report_nonfloating_toc', action='store_true', help='Do not float the table of contents (TOC) in output HTML report, default: %(default)s')
#optional_other.add_argument('--report_table_display', choices = ['full','light'], default='light', help="Set the level of detail/comprehensiveness in interactive datables of HTML report, very comprehensive (option 'full') or slim/focused ('light'), default: %(default)s")
optional_other.add_argument('--ignore_noncoding', action='store_true',dest='ignore_noncoding',default=False,help='Ignore non-coding (i.e. non protein-altering) variants in report, default: %(default)s')
optional_other.add_argument("--debug", action="store_true", help="Print full commands to log")
optional_other.add_argument("--pcgrr_conda", default="pcgrr", help="pcgrr conda env name (default: %(default)s)")
Expand Down
2 changes: 1 addition & 1 deletion pcgr/pcgr_vars.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
VEP_MAX_FORKS = 8
VEP_MIN_BUFFER_SIZE = 50
VEP_MAX_BUFFER_SIZE = 30000
VEP_PICK_CRITERIA = ['mane','canonical','appris','tsl','biotype','ccds','rank','length']
VEP_PICK_CRITERIA = ['mane_select','mane_plus_clinical','canonical','appris','tsl','biotype','ccds','rank','length']

tsites = {
0: 'Any',
Expand Down

0 comments on commit c809907

Please sign in to comment.