and 1 contributors
GenOOx::Data::File::SAMstar::Record - Represents a record of a SAM format file generated by STAR
# Object representing a record of a sam file # To initialize my $sam_record = GenOOx::Data::File::SAMstar::Record->new( fields => [qname,flag, rname, pos, mapq, cigar, rnext, pnext, tlen, seq, qual, tags] );
This object represents a record of a sam file generated by STAR 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.
# 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;