IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jul 30, 2010, 10:56:07 AM (16 years ago)
Author:
rhenders
Message:

Improvements to plot titles and x tics

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/czartool/Czarplot.pm

    r28783 r28802  
    189189        $divX = 7200;
    190190    }
    191     # if more than one day's data plotted, show daily tics
     191    # if less than 1 week's data is data plotted, show daily tics
     192    elsif ($timeDiff < 604800) {
     193       
     194        $timeFormat = "%m/%d";
     195        $divX = 86400;
     196    }
    192197    else {
    193        
    194         $timeFormat = "%m/%d %H:%M";
    195         $divX = 86400;
    196     }
     198
     199        $timeFormat = "%m/%d";
     200        $divX = 172800;
     201    }
     202
    197203
    198204    my $numOfPlots = keys %$gnuplotFiles;
     205    my $title = undef;
     206
     207    # sort out plot title
     208    if ($numOfPlots == 1) {foreach my $stage (keys %$gnuplotFiles) { $title = "'".$stage."'";}}
     209    else {$title = "'All stages'"}
    199210
    200211    open (GP, "|/usr/bin/gnuplot -persist") or die "no gnuplot";
     
    205216        "set term $self->{_outputFormat};" .
    206217        "set output \"$outputFile\";" .
    207         "set title \"All stages for '$label' since $fromTime\";" .
     218        "set title \"$title for '$label' since $fromTime\";" .
    208219        "set key left top;" .
    209220        "set xdata time;" .
Note: See TracChangeset for help on using the changeset viewer.