NAME

HitSeries

SYNOPSIS

    use HitSeries;

    my %User_Preferences = %Prefs::User_Preferences;
    $User_Preferences{'current_strain'} = $strain_name;

    my $pm = new Parallel::ForkManager($MAX_PROCESSES);

    my $hs = HitSeries->new(-consensus => $consensus, -forkmanager => \$pm, -prefs => \%User_Preferences);
    my @hit_series = $hs->generate();
        
    my %positional_alignments = generate_positional_alignments($strain_name);
    my $consensus_read_path = $results_path.$strain_name."_consensus_reads.".$datext;
    my %positional_consensus_reads = get_consensus_read_database($consensus_read_path, \@hit_series, \%positional_alignments);
        
    @agreement = $hs->process(\%positional_consensus_reads);
    $hs->parse_agreements(\@agreement);

DESCRIPTION

HitSeries is a module to generate and process a HitSeries object, as part of the TURNIP software package.

CONSTRUCTORS

HitSeries->new()

    my $hs = HitSeries->new(-consensus => $consensus, -prefs => \%User_Preferences);
    my $hs = HitSeries->new(-consensus => $consensus, -forkmanager => \$pm, -prefs => \%User_Preferences);

The new() class method constructs a new HitSeries object. new() accepts the following parameters:

-consensus

A string representing the consensus sequence for this strain

-forkmanager

You can provide an optional Parallel::ForkManager object, and this module will employ it to do the more heavyweight tasks like ascription validation at each position. If no ForkManager is supplied, no parallel processing will take place.

-prefs

You must provide a Prefs object to supply global TURNIP parameters to this module.

FEEDBACK

Reporting Bugs

Please report bugs to the author.

AUTHOR

Rob Davey

APPENDIX

The rest of the documentation details each of the object methods. Internal (private) functions are preceded by an underscore (_)

new

 Title   : new
 Usage   : $hitseries = HitSeries->new()
 Function: constructs a new HitSeries object
 Returns : HitSeries
 Args    : consensus, Parallel::ForkManager, Prefs

generate

 Title   : generate
 Usage   : @hseries = $hitseries->generate()
 Function: generates a new list of all the hit series (potential ascriptions) for this strain
 Returns : list
 Args    : NONE

process

 Title   : process
 Usage   : @agreement = $hitseries->process()
 Function: generates a new list of all the agreements (validated ascriptions) for this strain
 Returns : array of validated ascriptions (potentially variable reads above quality threshold)
 Args    : hashref of positional consensus reads (reads that are known to be invariant to the consensus)

parse_agreements

 Title   : parse_agreements
 Usage   : $hitseries->parse_agreements(\@agreements);
 Function: parses an agreement file and outputs summary text files
 Returns : NONE
 Args    : agreements arrayref