11 Dec 2018 13:25:00 UTC
- Distribution: Bio-ViennaNGS
- Source (raw)
- Browse (raw)
- How to Contribute
- KwaliteeBus factor: 0
- License: perl_5
- Perl: v5.10.0
- Activity24 month
- Download (1.21MB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest version++ed by:1 non-PAUSE userMTW Michael T. Wolfingerand 1 contributors
- Michael T. Wolfinger
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
Bio::ViennaNGS::FeatureIO - Versatile I/O interface for Bio::ViennaNGS feature annotation classes
use Bio::ViennaNGS::FeatureIO; # initialize a FeatureIO object from a Bed6 file my $data_bed = Bio::ViennaNGS::FeatureIO->new( file => "file.bed6", filetype => 'Bed6', instanceOf => 'Feature', base => 0, ); # initialize a FeatureIO object from a Bed12 file my $data_bed = Bio::ViennaNGS::FeatureIO->new( file => "file.bed12", filetype => 'Bed12', instanceOf => 'Bed', base => 0, ); # initialize a FeatureIO object from a bedGraph file my $obj = Bio::ViennaNGS::FeatureIO->new(file => "file.bg", filetype => "BedGraph", instanceOf => "BedGraph", base => 0, );
This module provides an object-oriented interface for easy input/output operations on common feature annotation file formats. It is - by design - a very generic module that stores all annotation data within the
$self->filetypespecifies the file type to be processed. Currently parsing of Bed6, Bed12 and bedGraph files is supported.
$self->instanceOfdetermines the object type of elements held in the
In case of parsing Bed6 data,
$self->instanceOfcan either be
FeatureChainBlock. While the first causes
$self->datato hold an ArrayRef to individual Bio::ViennaNGS::Feature objects, the second triggers creation of individual Bio::ViennaNGS::FeatureChain objects (each containing exactly one feature interval, corresponding to individual Bed6 entries). A
FeatureChainBlockvalue to the
$self->datato hold an ArrayRef to a combined Bio::ViennaNGS::FeatureChain containing an entire block of features. In the context of Bed annotation this corresponds to a single Bed12 line (e.g. gene/transcript) that contains all individual Bed6 features (e.g. exons). Evidently, this only makes sense if all Bed6 features originate from the same chromosome and strand.
In case of parsing Bed12 data, currently only
Bedis supported for
$self->datato hold an ArrayRef to Bio::ViennaNGS::Bed (aka Bed12) features. This will be adjusted to Bio::ViennaNGS::FeatureChain in the future.
In case of pasring bedGraph data,
$self->instanceOfis ignored and
$self->dataholds an ArrayRef to individual Bio::ViennaNGS::BedGraph objects.
These methods are used for object construction and should not be called directly.
Michael T. Wolfinger <email@example.com>
Copyright (C) 2014-2018 Michael T. Wolfinger <firstname.lastname@example.org>
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.10.0 or, at your option, any later version of Perl 5 you may have available.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
Module Install Instructions
To install Bio::ViennaNGS, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell install Bio::ViennaNGS
For more information on module installation, please visit the detailed CPAN module installation guide.