src/hg/encode/encodeValidate/doEncodeValidate.pl 1.223
1.223 2010/04/28 23:14:08 braney
add support for bigWig's to put min and max in trackDb file
Index: src/hg/encode/encodeValidate/doEncodeValidate.pl
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/hg/encode/encodeValidate/doEncodeValidate.pl,v
retrieving revision 1.222
retrieving revision 1.223
diff -b -B -U 4 -r1.222 -r1.223
--- src/hg/encode/encodeValidate/doEncodeValidate.pl 22 Apr 2010 20:57:07 -0000 1.222
+++ src/hg/encode/encodeValidate/doEncodeValidate.pl 28 Apr 2010 23:14:08 -0000 1.223
@@ -2013,8 +2013,22 @@
print TRACK_RA " subGroups $subGroups\n";
if($type eq 'wig') {
my $placeHolder = Encode::wigMinMaxPlaceHolder($tableName);
print TRACK_RA " type $type $placeHolder\n";
+ } elsif($type eq 'bigWig') {
+ my @cmds;
+ my $tmpFile = $Encode::autoCreatedPrefix . $type ;
+ push @cmds, "bigWigInfo -minMax @{$ddfLine->{files}}";
+ my $safe = SafePipe->new(CMDS => \@cmds, STDOUT => $tmpFile, DEBUG => $opt_verbose - 1);
+ if(my $err = $safe->exec()) {
+ print STDERR "ERROR: failed bigWigInfo: " . $safe->stderr() . "\n";
+ # don't show end-user pipe error(s)
+ pushError(\@errors, "failed creation of trackDb");
+ }
+ my $lines = Encode::readFile($tmpFile);
+ my $line = shift(@{$lines});
+ print TRACK_RA " type bigWig " . $line . "\n";
+
} elsif($type eq 'gtf') { # GTF is converted to and loaded as genePred
print TRACK_RA " type genePred\n";
} elsif($type eq 'tagAlign') { # tagAligns are bed 6 but with column called 'sequence' instead of 'name'
print TRACK_RA " type bed 6\n";