NAME

CracTools::GFF::Annotation - Parse GFF lines.

VERSION

version 1.22

SYNOPSIS

use CracTools::GFF::Query;

# Creating the reader
my $gffQuery = CracTools::GFF::Query->new('annotations.gff');

my @annotations = $gffQuery->fetchByLocation('1',298345,'+');

foreach my $gff_line (@annotations) {
  my $annotation = CracTools::GFF::Annotation->new($gff_line);
  print "Gene_id : ",$annotation->attribute('gene_id'),"\n";
}

DESCRIPTION

This module defines an object to easily parse and access GFF line's fields.

TODO

Set Parent for feature in GTF format (gene_id for transcript and transcript_id for exons).

METHODS

new

Arg [1] : String - $line
          GFF line
Arg [2] : String - $format (optional) - default 'gff3'
          GFF format (gtf or gff3)

Example     : my $annotation = CracTools::GFF::Annotation->new($gff_line);
Description : Create a new CracTools::GFF::Annotation object
              If a gff line is passed in argument, the line will be parsed
              and loaded.
ReturnType  : CracTools::GFF::Query

GETTERS AND SETTERS

chr

Description : Getter/setter for attribute chr

source

Description : Getter/setter for attribute source

feature

Description : Getter/setter for attribute feature

start

Description : Getter/setter for attribute start

end

Description : Getter/setter for attribute end

score

Description : Getter/setter for attribute score

strand

Description : Getter/setter for attribute strand ('1','-1' convention)

gffStrand

Description : Return strand using "+","-" convention.

phase

Description : Getter/setter for attribute phase

parents

Description : Getter for attribute parents.
ReturnType  : Array of strings with parents ID

attribute

Description : Getter/setter for attribute attribute

AUTHORS

  • Nicolas PHILIPPE <nphilippe.research@gmail.com>

  • Jérôme AUDOUX <jaudoux@cpan.org>

  • Sacha BEAUMEUNIER <sacha.beaumeunier@gmail.com>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2015 by IRMB/INSERM (Institute for Regenerative Medecine and Biotherapy / Institut National de la Santé et de la Recherche Médicale) and AxLR/SATT (Lanquedoc Roussilon / Societe d'Acceleration de Transfert de Technologie).

This is free software, licensed under:

The GNU Affero General Public License, Version 3, November 2007