[Bioperl-l] getting/setting species names with Bio::Species

Dave Messina David.Messina at sbc.su.se
Fri Jan 15 13:37:17 EST 2010


Thanks guys.

Well, looks like I ignored the deprecation warnings at my own peril. :)

I'll reimplement my code using Bio::Taxon directly instead. I made a little test using the node_name() method as Chris suggested, and it seems to do the trick nicely.


> If that's really what the documentation says, it's wrong.

I'm afraid so. In the POD
>  Title   : species
>  Usage   : $self->species( $species );
>            $species = $self->species();
>  Function: Get or set the scientific species name.
>  Example : $self->species('Homo sapiens');
>  Returns : Scientific species name as string
>  Args    : Scientific species name as string

and the HOWTO 
http://www.bioperl.org/wiki/HOWTO:Feature-Annotation#The_Species_Object
> # legible and long
> my $species_object = $seq_object->species;
> my $species_string = $species_object->species;
> 
> # Perlish
> my $species_string = $seq_object->species->species;
> # either way, $species_string is "Homo sapiens"



Unless there's objection, I'll fix both of those.


> It is the binomial() method that does this (as getter and setter).

Great, thanks for the clarification, Hilmar.






More information about the Bioperl-l mailing list