[Bio] / FigKernelPackages / Quality.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/Quality.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3, Wed Nov 22 20:22:02 2006 UTC revision 1.5, Fri Dec 1 21:39:11 2006 UTC
# Line 42  Line 42 
42  set the optional argument C<$estimated_read_length> to C<100> for genomes  set the optional argument C<$estimated_read_length> to C<100> for genomes
43  sequenced using the "454" technology.  sequenced using the "454" technology.
44    
45  Returns a list of two strings: C<($depth, $completness)>.  Returns a list of two strings on success, C<($depth, $completness)>,
46    and an empty list on failure.
47    
48  =cut  =cut
49    
# Line 51  Line 52 
52    
53      if (!-d $org_dir) {      if (!-d $org_dir) {
54          warn "OrgDir $org_dir does not exist";          warn "OrgDir $org_dir does not exist";
55          return (undef, undef);          return ();
56      }      }
57    
58      if (not defined($estimated_read_length)) {      if (not defined($estimated_read_length)) {
# Line 62  Line 63 
63      my $completeness;      my $completeness;
64      if (!-s "$org_dir/contigs") {      if (!-s "$org_dir/contigs") {
65          warn "Contigs file $org_dir/contigs does not exist";          warn "Contigs file $org_dir/contigs does not exist";
66          return (undef, undef);          return ();
67      }      }
68      else {      else {
69          my $summary = `sequence_length_histogram -null $org_dir/contigs 2>&1`;          my $summary = `sequence_length_histogram -null $org_dir/contigs 2>&1`;
# Line 116  Line 117 
117  The "Skeleton OrgDir" directory-path argument C<$org_dir> is mandatory,  The "Skeleton OrgDir" directory-path argument C<$org_dir> is mandatory,
118  and does not default to a directory in the SEED organism hierarchy.  and does not default to a directory in the SEED organism hierarchy.
119    
120  The routine returns a list of pointers to two hashes, C<($fatal, $warnings)>,  On success, the routine returns a list of pointers to two hashes, C<($fatal, $warnings)>,
121  whose keys are the type of error in each class, and whose values are the  whose keys are the type of error in each class, and whose values are the
122  number of features having that type of error.  number of features having that type of error; on failure, it returns the empty list.
123    
124  As a side-effect, this routine creates three files in the skeleton OrgDir:  As a side-effect, this routine creates three files in the skeleton OrgDir:
125    
# Line 153  Line 154 
154    
155      if (!-d $org_dir) {      if (!-d $org_dir) {
156          warn "OrgDir $org_dir does not exist\n";          warn "OrgDir $org_dir does not exist\n";
157          return (undef, undef);          return ();
158      }      }
159      my $parent   = basename($org_dir) || confess "Could not extract parent of $org_dir";      my $parent   = basename($org_dir) || confess "Could not extract parent of $org_dir";
160    
161      my $fatal    = {};      my $fatal    = {};
162      my $warnings = {};      my $warnings = {};
163      if (system("assess_gene_call_quality --metas=$parent/meta.xml  $org_dir > $org_dir/quality.report 2>&1")) {      if (system("assess_gene_call_quality --meta=$parent/meta.xml  $org_dir > $org_dir/quality.report 2>&1")) {
164          warn "FAILED: assess_gene_call_quality $org_dir > $org_dir/quality.report 2>&1";          warn "FAILED: assess_gene_call_quality $org_dir > $org_dir/quality.report 2>&1";
165          return (undef, undef);          return ();
166      }      }
167    
168      my @report = `cat $org_dir/quality.report`;      my @report = `cat $org_dir/quality.report`;

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.5

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3