NAME
Bio::Lite - Bio::Lite is a perl module that aims to answer the same questions as Bio-perl, FASTER and using a SIMPLIFIED API.
VERSION
version 0.001
SYNOPSIS
Keep it simple, keep it fast.
Bio::Lite is a set of subroutines that aim to answer similar question as Bio-perl distribution without the complexity.
Bio::Lite is fast, simple and does not make use of complexe data struture and object that lead to slow execution.
All methods can be imported with a single "use Bio::Lite"
Bio::Lite is also a lightweigth, single, module with no dependencies.
UTILS
reverseComplemente
Reverse complemente the (nucleotid) sequence in arguement.
PARSING
This are some tools that aim to read (bio) files like - Sequence files : FASTA, FASTQ - Annotation files : GFF3, GTF2, BED6, BED12, ... - Alignement files : SAM, BAM -
seqFileIterator
Open Fasta, or Fastq files (can be gziped). seqFileIterator has an automatic file extension detection but you can force it using a second parameter with the format : 'fasta' or 'fastq'
my $it = seqFileIterator('file.fastq','fastq');
while(my $entry = $it->()) {
print "Sequence name : $entry->{name}
Sequence : $entry->{seq}
Sequence quality: $entry->{qual}","\n";
}
pairedEndSeqFileIterator
Open Paired-End Sequence file unsing seqFileIterator()
my $it = pairedEndSeqFileIterator($file);
while (my $entry = $it->()) {
print "Read_1 : $entry->{read1}->{seq}
Read_2 : $entry->{read2}->{seq}";
}
gffFileIterator
manage GFF3 and GTF2 file format
Return a hashref with the annotation parsed :
{ chr => ...,
source => ...,
feature => ...,
start => ...,
end => ...,
strand ...,
frame ...,
attributes => { id => val, ...}
}
FILES IO
getReadingFileHandle
Return a file handle for the file in argument. Display errors if file cannot be oppenned and manage gzipped files (based on .gz file extension)
TODO
- add a seqFileIterator that manage paired-end files
AUTHOR
Jérôme Audoux <jerome.audoux@gmail.com>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2014 by Jérôme Audoux.
This is free software, licensed under:
The GNU General Public License, Version 3, June 2007