[Bioperl-l] pdb.pm and annotations
Mark A. Jensen
maj at fortinbras.us
Tue Dec 22 02:51:32 UTC 2009
Hi Sung--
We didn't plan it, but we added it anyway: see revision 16559 of
bioperl-live/trunk.
You can then do
$pmid = ($struct->annotation->get_Annotations('reference'))[0]->pubmed;
and even
$doi = ($struct->annotation->get_Annotations('reference'))[0]->doi;
Thanks for the heads-up!
cheers,
MAJ
----- Original Message -----
From: "Sungsam Gong" <sung at bio.cc>
To: <bioperl-l at lists.open-bio.org>
Sent: Wednesday, December 16, 2009 12:55 PM
Subject: [Bioperl-l] pdb.pm and annotations
> Hi,
>
> Wanted to get pubmed identifier from a PDB file using Bio::Structure,
> so hacked the code.
> Knew that Bio::Structure::IO::pdb.pm get relevant info from either
> 'JRNL' or 'REMARK 1'.
> However could not see any actual code parsing 'PMID'.
>
>>From pdb.pm, what I see:
>
> sub _read_PDB_jrnl {
> ...
> $auth = $self->_concatenate_lines($auth,$rol) if ($subr eq "AUTH");
> $titl = $self->_concatenate_lines($titl,$rol) if ($subr eq "TITL");
> $edit = $self->_concatenate_lines($edit,$rol) if ($subr eq "EDIT");
> $ref = $self->_concatenate_lines($ref ,$rol) if ($subr eq "REF");
> $publ = $self->_concatenate_lines($publ,$rol) if ($subr eq "PUBL");
> $refn = $self->_concatenate_lines($refn,$rol) if ($subr eq "REFN");
> ...
> }
>
> sub _read_PDB_remark_1 {
> ...
> $auth = $self->_concatenate_lines($auth,$rol) if
> ($subr eq "AUTH");
> $titl = $self->_concatenate_lines($titl,$rol) if
> ($subr eq "TITL");
> $edit = $self->_concatenate_lines($edit,$rol) if
> ($subr eq "EDIT");
> $ref = $self->_concatenate_lines($ref ,$rol) if
> ($subr eq "REF");
> $publ = $self->_concatenate_lines($publ,$rol) if
> ($subr eq "PUBL");
> $refn = $self->_concatenate_lines($refn,$rol) if
> ($subr eq "REFN");
> ...
> }
>
>>From my script, I did:
>
> ($struc->annotation->get_Annotations('reference'))[0]->authors
> ($struc->annotation->get_Annotations('reference'))[0]->title
>
> or
>
> my $hash_ref=($struc->annotation->get_Annotations('reference'))[0]->hash_tree
> for my $key (keys %{$hash_ref}) {
> print $key,": ",$hash_ref->{$key},"\n";
> }
>
> Any plan to include a code chopping 'PMID' out?
> Or did I miss something?
>
> Cheers,
> Sung
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>
>
More information about the Bioperl-l
mailing list