Commit a12e8938 by Mustafa Tekpinar

Some changes to make the program run on python3 (tested with 3.9.7 ).

parent f61b87d1
*~
._*
\ No newline at end of file
._*
.Rhistory
example/.RData
gemmeAnal.pyc
\ No newline at end of file
......@@ -135,14 +135,14 @@ def doit(inAli,mutFile,retMet,bFile,fFile,n,N):
createPDB(prot,seq)
print "query protein: "+prot
print "computing conservation levels..."
print("query protein: "+prot)
print("computing conservation levels...")
#I intend to run JET2 completely externally!!
#It is too much buggy and it has too many dependencies.
#Using it with a Docker or Singularity may be the best solution!
launchJET(prot,retMet,bFile,fFile,n,N,nl)
print "done"
print("done")
launchPred(prot,inAli,mutFile)
cleanTheMess(prot,bFile,fFile)
......
......@@ -62,8 +62,7 @@ def createPDB(prot,seq):
# Edit JET configuration file with correct number of Seqs & MSA
def editConfJET(N):
reCode=subprocess.call("sed -i 's/results\t\t5000/results\t\t"+str(N)+"/' default.conf",shell=True)
reCode=subprocess.call("sed -i 's/results\t\t5000/results\t\t"+str(N)+"/' default.conf",shell=True)
return(reCode)
# Run JET to compute TJET values
......@@ -105,10 +104,14 @@ def launchJET(prot,retMet,bFile,fFile,n,N,nl):
subprocess.call("cp $GEMME_PATH/default.conf .",shell=True)
if retMet=="input":
if bFile!='':
subprocess.call("cp "+bFile+" "+prot+"_A.psiblast",shell=True)
if(bFile == prot+"_A.psiblast"):
shutil.copy2(bFile, bFile+".orig")
shutil.copy2(bFile+".orig ", prot+"_A.psiblast")
else:
shutil.copy2(bFile+" ", prot+"_A.psiblast")
jetcmd = "java -Xmx1000m -cp $JET2_PATH:$JET2_PATH/jet/extLibs/vecmath.jar jet.JET -c default.conf -i "+prot+".pdb -o `pwd` -p J -r input -b "+prot+"_A.psiblast -d chain -n "+n+" > "+prot+".out"
else:
print N
print(N)
editConfJET(N)
if(fFile == prot+"_A.fasta"):
......@@ -139,7 +142,7 @@ def launchPred(prot,inAli,mutFile):
else:
rcmd="Rscript --save $GEMME_PATH/computePred.R "+prot+" "+inAli+" TRUE none"
print rcmd
print("\nRunning: \n"+rcmd)
reCode=subprocess.call(rcmd,shell=True)
#Add plots here with gemmemore
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment