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

Dev #51

Merged
merged 7 commits into from
Sep 5, 2023
Merged

Dev #51

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 scorpio/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
_program = "scorpio"
__version__ = "0.3.18"
__version__ = "0.3.19"
12 changes: 10 additions & 2 deletions scorpio/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,21 +134,24 @@ def main(sysargs = sys.argv[1:]):
'--in-groups', dest='in_groups', required=False,
help='CSV of containing sequence_name and a column defining groups ')
subparser_define.add_argument(
'--group-column', dest='group_column', required=False, default='lineage',
'--group-column', dest='group_column', required=False, default=None,
help='Column name defining the groups')
subparser_define.add_argument(
'--index-column', dest='index_column', required=False, default='sequence_name',
help='Taxon column name')
subparser_define.add_argument("--subset", dest="subset", required=False, nargs='+',
help="Names of a subset of groups to define")
subparser_define.add_argument("--threshold-common", dest="threshold_common", required=False, type=float,
default=0.98, help="Frequency of a variant within group to be considered common")
default=0.8, help="Frequency of a variant within group to be considered common")
subparser_define.add_argument("--threshold-intermediate", dest="threshold_intermediate", required=False, type=float,
default=0.25, help="Frequency of a variant within group to be reported as intermediate")
subparser_define.add_argument(
'--outgroups', dest='outgroups', required=False,
help='Two column CSV with group, and pipe separated list of outgroup sequence_names for that list. '
'Assumes outgroups will be in main input CSV')
subparser_define.add_argument(
'--outgroup-json', dest='outgroup_json', required=False,
help='A single JSON constellation file defining an outgroup for all sequences')
subparser_define.add_argument(
"--protein", dest="protein", action="store_true",
help="Translates definition coordinates to proteins where possible"
Expand Down Expand Up @@ -248,6 +251,11 @@ def main(sysargs = sys.argv[1:]):
for c in args.constellations:
logging.info(c)
logging.info("\n")
elif not args.constellations and args.command in ['define'] and args.outgroup_json and not args.outgroup_json.endswith(".json"):
for c in list_constellation_files:
if args.outgroup_json in c:
logging.info("Using constellation file %s for outgroup %s" %(c,args.outgroup_json))
args.outgroup_json = c

if "call_all" in args and args.call_all and args.long and args.verbose:
logging.info("Cannot provide long format summary file with multiple calls, ignoring --long\n")
Expand Down
Loading
Loading