# HG changeset patch
# User johnheap
# Date 1559686314 14400
# Node ID c0a6a170163e04fe74962a0f10ada7dd94bbd051
# Parent 728b1d375b41c7b0d53e750dcb9fb4c04eb819fa
Uploaded
diff -r 728b1d375b41 -r c0a6a170163e Tryp_V_T.py
--- a/Tryp_V_T.py Tue Jun 04 18:03:36 2019 -0400
+++ b/Tryp_V_T.py Tue Jun 04 18:11:54 2019 -0400
@@ -120,7 +120,10 @@
def blastContigs(test_name,html_resource, database):
db_path = database
- argString = "blastx -db "+db_path+" -query "+test_name+"_for_blast.fa -outfmt 10 -out "+test_name+"_blast.txt"
+ #argString = "makeblastdb - in " + db_path
+ #subprocess.call(argString, shell=True)
+
+ argString = "blastx -db " + db_path + " -query "+test_name+"_for_blast.fa -outfmt 10 -out "+test_name+"_blast.txt"
print(argString)
returncode = subprocess.call(argString, shell=True)
if returncode != 0:
@@ -224,7 +227,7 @@
imgString = r"
"
htmlString += imgString
- with open(tdict['html_file'], "w") as htmlfile:
+ with open(tdict['html_resource']+'/'+tdict['html_file'], "w") as htmlfile:
htmlfile.write(htmlString)
@@ -236,7 +239,7 @@
def combineFPMK(tdict):
dir_path = os.path.dirname(os.path.realpath(__file__))+'/'
- fpkm_df = pd.read_csv(dir_path++tdict['name']+'.cuff/genes.fpkm_tracking', sep='\t')
+ fpkm_df = pd.read_csv(dir_path+tdict['name']+'.cuff/genes.fpkm_tracking', sep='\t')
#fpkm_df = pd.read_csv('genes.fpkm_tracking',sep='\t')
#print(fpkm_df.head())
@@ -392,9 +395,9 @@
plt.subplots_adjust(bottom=0.1, top=0.9, left=0.15, right=0.9)
ax.set_title(title, x=0, wrap='True',ha='left',)
- plt.savefig(tdict['html_resource'] + tdict['name']+"_phylotypes.png")
+ plt.savefig(tdict['html_resource'] + '/' + tdict['name']+"_phylotypes.png")
if tdict['pdf'] == 'PDF_Yes':
- plt.savefig(tdict['html_resource'] + tdict['name']+"phylotypes.pdf")
+ plt.savefig(tdict['html_resource'] + '/' + tdict['name']+"phylotypes.pdf")
# plt.show()
pass