I have some trouble getting blast (command-line) and biopython work together. I want a pipeline that runs a single protein query against a blast database, and returns a multiple sequence alignment of hits into python, where I can do further analysis on it.
In tblastn, I can choose the output - my desired format would be "3 = flat query-anchored, show identities", which returns a multiple sequence alignment. Unfortunately, this is, as far as I understand, not really compatible with biopython.
Biopython instead accepts e.g. a blast-xml file as input, which can be selected as an output from tblastn. However, from an xml, in biopython I am only able to extract pairwise alignments - the MSA seems to be lost. The Bio.Blast.record class does even have a multiple_alignment method, but it returns 'None' all the time.
I hope my problem is understandable - does anyone have experience in how to get the 'query-anchored' output from blast into (bio)python?