Mercurial > repos > johnheap > vapper_galaxy
changeset 7:08b35d28e826 draft
Uploaded
author | johnheap |
---|---|
date | Wed, 04 Jul 2018 11:33:15 -0400 |
parents | 7009f696a60a |
children | 04b8c470736b |
files | Vap.py |
diffstat | 1 files changed, 91 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Vap.py Wed Jul 04 11:33:15 2018 -0400 @@ -0,0 +1,91 @@ +""" + * Copyright 2018 University of Liverpool + * Author: John Heap, Computational Biology Facility, UoL + * Based on original scripts of Sara Silva Pereira, Institute of Infection and Global Health, UoL + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + """ +#import subprocess +#import re +import os +import sys +#import pandas as pd +#import numpy as np +#import seaborn as sns +#import matplotlib.pyplot as plt +#from matplotlib.mlab import PCA +import Tryp_G +import Tryp_T +import Tryp_V +import argparse +#Entry .sort out the arguments + +pdfExport = False +#parser = argparse.ArgumentParser(description='Variant Antigen Profiler - the VAP.') +#parser.add_argument('name') +#parser.add_argument('-t','-T', action = 'store_true', default = False, help = "Transciptomic Pathway") +#parser.add_argument('-p','-P', action = 'store_true', default = False, help = "Export PDFs to HTML directory") +#parser.add_argument('strain') +#parser.add_argument('Forward_Read_File') +#parser.add_argument('Reverse_Read_File') +#parser.add_argument('htmlfile') +#parser.add_argument('htmlresource') +#parser.add_argument('heatmapFile') +#parser.add_argument('PCAFile') +#parser.add_argument('devheatmapFile') +#args = parser.parse_args() + +#we have numerous parameters.... +#hard code it for differnt types? + + +arguments = sys.argv +htmldir = arguments[len(arguments)-1] #last argument is always html_resource +if not os.path.exists(htmldir): + os.mkdir(htmldir) + +if arguments[1] == 'g_assemble': + argdict = {'name':2, 'pdfexport':3, 'kmers':4,'inslen':5, 'covcut':6, 'forward':7, 'reverse':8, 'html_file':9, 'html_resource':10} + Tryp_G.assemble(arguments,argdict) +if arguments[1] == 'g_contigs': + argdict = {'name':2, 'pdfexport':3, 'contigs':4, 'html_file':5, 'html_resource':6} + Tryp_G.contigs(arguments,argdict) +if arguments[1] == 'transcipt': + argdict = {'name':2, 'pdfexport': 3, 'strain': 4, 'forward': 5, 'reverse': 6, 'html_file': 7, 'html_resource': 8} + Tryp_T.transcriptomicProcess(arguments,argdict) +if arguments[1] == 'v_assemble': + argdict = {'name':2, 'pdfexport':3, 'kmers':4,'inslen':5, 'covcut':6, 'forward':7, 'reverse':8, 'html_file':9, 'html_resource':10} + Tryp_V.vivax_assemble(arguments,argdict) +if arguments[1] == 'v_contigs': + argdict = {'name':2, 'pdfexport':3, 'contigs':4, 'html_file':5, 'html_resource':6} + Tryp_V.vivax_contigs(arguments,argdict) + + +sys.exit() + + + +#if not os.path.exists(args.htmlresource): +# os.mkdir(args.htmlresource) +#if args.p: +# pdfExport = True +#if args.t: +# print ("Transcriptomic Pathway") +# Tryp_T.transcriptomicProcess(args.name, pdfExport, args.strain, args.Forward_Read_File, args.Reverse_Read_File, args.htmlfile, args.htmlresource) +#else: + #print ('Genomic Pathway') + #Tryp_G.test_output(args.name, args.htmlfile, args.htmlresource, args.heatmapFile, args.PCAFile,args.devheatmapFile) +# Tryp_G.genomicProcess(args.name, pdfExport, args.Forward_Read_File, args.Reverse_Read_File, args.htmlfile, args.htmlresource) + +