Example Python code for ViennaRNA
0
0
Entering edit mode
3.6 years ago

Hi Biostars,

I'm trying to work with the Python distribution of ViennaRNA. I've found almost no documentation, except for a few examples posted here:

https://www.tbi.univie.ac.at/RNA/ViennaRNA/doc/html/helloworld_swig.html#helloworld_python

I can replicate these, but I'm lost trying to use functions not included in these examples. I'm particularly interested in code that compares the distance of secondary structures, for example by using RNA.make_tree() and RNA.tree_edit_distance(). Anyone have functioning Python code for this? Otherwise, anyone know where to find relevant documentation?

Thanks, Josh

RNA folding ViennaRNA Python • 1.7k views
ADD COMMENT
1
Entering edit mode

It seems that the python library is just wrapper code around the original C binaries. I can't see any python-specific documentation either really, so you are probably just going to have to do some trial and error and look at the source code for the wrapper functions.

You can inspect python objects with dir(thing) and help(thing) which might get you some of the way. You may have to refer to the documentation for the C programs to understand what the expected inputs etc are going to be I'm afraid.

ADD REPLY

Login before adding your answer.

Traffic: 2998 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6