NAME

Bio::Phylo::Parsers - A library for parsing phylogenetic data files and strings

SYNOPSIS

my $parser = new Bio::Phylo::Parsers;
$parser->parse(-file => 'data.nex', -format => 'Nexus');

DESCRIPTION

The Bio::Phylo::Parsers object is the unified 'front door' for parsing trees, lists of taxa and data matrices. It imports the appropriate subclass at runtime based on the '-format' argument.

CONSTRUCTOR

new()
Type    : Constructor
Title   : new
Usage   : my $parser = new Bio::Phylo::Parsers;
Function: Initializes a Bio::Phylo::Parsers object.
Returns : A Bio::Phylo::Parsers object.
Args    : none.
parse(%options)

The parse method makes assumptions about the capabilities of Bio::Phylo::Parsers::* modules: i) their names match those of the -format => (blah) arguments, insofar that ucfirst(blah) . '.pm' is an existing module; ii) the modules can either parse from_handle, i.e. from a file handle that gets passed to them, or from_string (i.e. from a scalar). I can see this expand to include the capability to parse from a database handle, and perhaps from a URL.

Type    : Parsers
Title   : parse(%options)
Usage   : $parser->parse(%options);
Function: Creates (file) handle, instantiates appropriate parser.
Returns : L<Phylo> object
Args    : -file => (path), -string => (scalar),
          -format => (description format), -other => (parser specific options)

AUTHOR

Rutger Vos, <rvosa@sfu.ca>

BUGS

Please report any bugs or feature requests to bug-phylo@rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Phylo. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

ACKNOWLEDGEMENTS

The author would like to thank Jason Stajich for many ideas borrowed from BioPerl http://www.bioperl.org, and CIPRES http://www.phylo.org and FAB* http://www.sfu.ca/~fabstar for comments and requests.

COPYRIGHT & LICENSE

Copyright 2005 Rutger Vos, All Rights Reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.