NAME

CracTools::GFF::Annotator - Generic annotation base on CracTools::GFF::Query.pm

SYNOPSIS

DESCRIPTION

METHODS

new

Arg [1] : String - $gff_file
          GFF file to perform annotation

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
Exceptions  : none

foundSameGene

Arg [1] : String - chr
Arg [2] : String - pos_start1
Arg [3] : String - pos_end1
Arg [4] : String - pos_start2
Arg [5] : String - pos_end1
Arg [6] : String - strand

Description : Return true if a gene is found between [pos_start1.pos_end1] and
              [pos_start2,pos_end2]
ReturnType  : Boolean
Exceptions  : none

getBestAnnotationCandidate

Arg [1] : String - chr
Arg [2] : String - pos_start
Arg [3] : String - pos_end
Arg [4] : String - strand
Arg [5] : (Optional) Subroutine - see C<getCandidatePriorityDefault> for more details

Description : Return best candidate annotation according to the priorities given
              by the subroutine in argument.
ReturnType  : Hash( feature_name => CracTools::GFF::Annotation, ...), Int(priority), String(type)

getBestAnnotationCandidate

Arg [1] : String - chr
Arg [2] : String - pos_start
Arg [3] : String - pos_end
Arg [4] : String - strand

Description : Return an array with all annotation candidates overlapping the
              chromosomic region.
ReturnType  : Array of Hash( feature_name => CracTools::GFF::Annotation, ...)

getCandidatePriorityDefault

Arg [1] : String - pos_start
Arg [2] : String - pos_end
Arg [3] : hash - candidate

Description : Default method used to give a priority to a candidate.
              You can create your own priority method to fit your specific need
              for selecting the best annotation.
              The best priority is 0. A priority of -1 means that this candidate
              should be avoided.
ReturnType  : ($priority,$type)

PRIVATE METHODS

_init

_constructCandidate