Hello,
I used the following code to run clustalw.I got an alignment file using this code. But I need to get pairwise sequence alignment score and also has to get distance matrix based on sequence identity.My aim is to do hierarchical clustering. How can I do these things with biopython.
import os
from Bio.Align.Applications import ClustalwCommandline
clustalw_exe = r"C:\Program Files\clustalw2\clustalw2.exe"
clustalw_cline = ClustalwCommandline(clustalw_exe, infile="C:\Users\pp\Desktop\myseqs.fasta")
assert os.path.isfile(clustalw_exe), "Clustal W executable missing"
stdout, stderr = clustalw_cline()
from Bio import AlignIO
align = AlignIO.read("C:\Users\pp\Desktop\myseqs.aln", "clustal")
print align
So you basically want to build a phylogenetic tree?
Thanks for your comment. Yes I would like to create a dendrogram.