[Bioperl-l] bioperl-network-1.5.2_100 node IDs
bosborne11 at verizon.net
Sun Jan 21 22:35:49 UTC 2007
All the ids are stored as Annotations, so each id is a
So to get at these you do something like this:
ok $node = $g1->get_nodes_by_id('PIR:A64696');
@proteins = $node->proteins;
my $ac = $proteins->annotation;
@ids = $ac->get_Annotations('dblink');
ok $ids->primary_id, "A64696";
By the way, it's frequently the case that a good source of example code are
the *t files in the t/ directory. The code above comes from t/ProteinNet.t,
You can also do:
%ids = $g1->get_ids_by_node($node);
This is not as Bioperl-ish but this is the way the modules were initially
Also, I've updated the documentation in IO/psi.pm, now you can easily tell
what is and what is not extracted from the XML and put in the Node object.
If there's something missing from the node that you're interested in you
should tell me and I'll see what I can do, I use this for my own work and
play and have only extracted data from the PSI MI XML that's useful for me
and not much else.
On 1/21/07 11:52 AM, "Mikel Egaña Aranguren"
<mikel.eganaaranguren at cs.man.ac.uk> wrote:
> is there a way of fine-tuning the types of ids that are stored in the
> Node objects, in the Bio::Network module?
> For example, if I have the following in an Intact psi xml file:
> <primaryRef db="uniprotkb" id="Q9Y738"
> secondary="mis12_schpo" version="SP_37"/>
> <secondaryRef db="interpro" id="IPR008685" secondary="Mis12"/>
> <secondaryRef db="intact" id="EBI-1002822"
> How can I retrieve the id "mis12_schpo"? At the moment it just gives me
> Thanks a lot.
More information about the Bioperl-l