This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Biopython - HiddenMarkovModel output

Hi there!

I am trying to use the function of HiddenMarkovModel that is in the module Bio.HMM.MarkovModel in Biopython. The problem is that when I run it, the output that appears on my screen is something I don't know what it is. Here it is:

HiddenMarkovModel(pr_dic, T_dic, E, T_dic, E)
Out[121]: <Bio.HMM.MarkovModel.HiddenMarkovModel at 0x7f622c13c160>

How can I get my sequence out of <Bio.HMM.MarkovModel.HiddenMarkovModel at 0x7f622c13c160>?

Thank you so much!

python biopython markovmodel

It's an object. You need to use one of the methods it contains to extract information from it.

Take a look at the biopython documentation for the class: https://biopython.org/docs/1.74/api/Bio.HMM.MarkovModel.html

At a glance it looks like it doesn't have a sequence emission, but has state emission functions, so you may need to use another class to actually emit the sequence from the HMM. I haven't used this bit of BioPython myself, so I don't know for sure.

Thank you so much!! I have read before that Biopython entry but I don't understand the information is displayed...

EDIT: Oh! I discovered how it works!! Thank you!!

0 answers

No answers yet.

Log in to answer this question.