Subject: | Cannot import a BioPerl tree |
An error is thrown when trying to convert a BioPerl tree object into a
Phylo tree object using Bio::Phylo v0.17_RC6:
Can't locate object method "Tree" via package "Bio::Phylo::Forest" at
/usr/local/share/perl/5.10.0/Bio/Phylo.pm line 198, <DATA> line 1.
A test script to reproduce the bug is attached.
Subject: | phylo_bp_import_bug.pl |
# Read tree in BioPerl
use Bio::TreeIO;
my $bptreeio = Bio::TreeIO->new(-format => 'newick',
-fh => \*DATA);
my $bptree = $bptreeio->next_tree;
# Convert BioPerl tree object to Phylo tree object
use Bio::Phylo::Forest::Tree;
my $phylo_tree = Bio::Phylo::Forest::Tree->new_from_bioperl($bptree);
# Some tree data
__DATA__
(((A:5,B:5)z:2,(C:4,D:4)y:1)x:3,E:10);