aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNavan Chauhan <navanchauhan@gmail.com>2020-10-03 19:11:04 +0530
committerNavan Chauhan <navanchauhan@gmail.com>2020-10-03 19:11:04 +0530
commit6fe0c3114b33471ae640ec5887f77b2ba33cc35c (patch)
treeec5705c93d18b7958931b451df06cfde01ee42b9
parente300d53d0d7877680fb0eeb2a8d5bcce3d6529e1 (diff)
added title,date to pdf
-rw-r--r--app/scripts/add-pictures.py2
-rw-r--r--app/scripts/get_dock_score.py10
-rwxr-xr-xapp/scripts/main.sh2
-rw-r--r--app/scripts/makeReport.py2
4 files changed, 11 insertions, 5 deletions
diff --git a/app/scripts/add-pictures.py b/app/scripts/add-pictures.py
index 95079f0..5d01c50 100644
--- a/app/scripts/add-pictures.py
+++ b/app/scripts/add-pictures.py
@@ -1,4 +1,4 @@
-print("## Figures", end="\n\n")
+print("# Figures", end="\n\n")
print("![Back View](output-back.png){width=100%}", end="\n\n")
print("![Front View](output-front.png){width=100%}", end="\n\n")
diff --git a/app/scripts/get_dock_score.py b/app/scripts/get_dock_score.py
index c8b87d5..c4cc30d 100644
--- a/app/scripts/get_dock_score.py
+++ b/app/scripts/get_dock_score.py
@@ -1,5 +1,5 @@
#!/usr/bin/python3
-
+from datetime import datetime
import argparse
parser = argparse.ArgumentParser(description="Get Docking Score")
@@ -21,7 +21,11 @@ ligand = args.ligand
from os.path import basename
-print("# " + str(basename(protein)).replace(".pdbqt","") + "-" + str(basename(ligand)).replace("_out.pdbqt",""), end="\n\n")
+print("% Molecular Docking of " + str(basename(ligand)).replace("_out.pdbqt","") + " with " +str(basename(protein)).replace(".pdbqt",""))
+print("%")
+print("% " + str(datetime.now().strftime("%b %d, %Y")))
+
+print("![Structure of %s](compound.svg)"%(str(basename(ligand)).replace("_out.pdbqt","")),end="\n\n")
from tabulate import tabulate
@@ -41,6 +45,6 @@ for line in lines:
if ta != []:
results.append(ta)
-print("## Docking Scores",end="\n\n")
+print("# Docking Score",end="\n\n")
print(tabulate(results,headers=["No.","Affinity","rmsd l.b","rmsd u.b"]))
print("",end="\n\n")
diff --git a/app/scripts/main.sh b/app/scripts/main.sh
index b1c789c..7ad044c 100755
--- a/app/scripts/main.sh
+++ b/app/scripts/main.sh
@@ -142,6 +142,8 @@ fi
if [[ $interactions == "true" ]]; then
file=$(echo "$ligandPath" | cut -f 1 -d '.')
python3 ./get-best.py -p $proteinPath -l "$(echo $file)_out.pdbqt"
+ echo "Generating SVG of Compound"
+ obabel $ligandPath -O compound.svg
echo "Running PLIP"
plip -f best.pdb -qpxy
echo "Getting Dock Score"
diff --git a/app/scripts/makeReport.py b/app/scripts/makeReport.py
index 4f693ac..e12569c 100644
--- a/app/scripts/makeReport.py
+++ b/app/scripts/makeReport.py
@@ -49,7 +49,7 @@ name = doc.report.pdbid.cdata
# print(("# " + (name.replace("_"," ")).replace("PROTEIN","")), end="\n\n")
fallback = 0
-print("## Visualisation", end="\n\n")
+print("# Visualisation", end="\n\n")
print(f"![]({image})", end="\n\n")
natural_ligands = []