Emmanouil "Manolis" Maragkakis
and 1 contributors

NAME

GenOOx::Data::File::SAMbwa::Record - Represents a record of a SAM format file generated by BWA

SYNOPSIS

    # Object representing a record of a sam file 

    # To initialize 
    my $sam_record = GenOOx::Data::File::SAMbwa::Record->new(
        fields => [qname,flag, rname, pos, mapq, cigar,
                   rnext, pnext, tlen, seq, qual, tags]
    );

DESCRIPTION

    This object represents a record of a sam file generated by BWA and offers methods for accessing the different
    attributes. It implements several additional methods that transform original attributes in more manageable
    attributes. eg. from the FLAG attribute the actual strand is extracted etc.

EXAMPLES

    # Check if the record corresponds to a match
    my $mapped = $sam_record->is_mapped;
    
    # Check if the record corresponds to a non match
    my $unmapped = $sam_record->is_unmapped;
    
    # Parse the FLAG attribute and return 1 or -1 for the strand
    my $strand = $sam_record->strand;