SUMAX - get trace by trace local/global maxima, minima, or absolute maximum

 sumax <stdin >stdout [optional parameters]                      

 Required parameters:                                      
      none                                           

 Optional parameters:                                      
      output=ascii            write ascii data to outpar         
                        =binary for binary floats to stdout
                        =segy for SEGY traces to stdout          

      mode=maxmin       output both minima and maxima      
                        =max maxima only             
                        =min minima only             
                        =abs absolute maxima only                

      verbose=0         writes global quantities to outpar 
                        =1 trace number, values, sample location

      outpar=/dev/tty         output parameter file; contains output   
                              from verbose                 

 Examples:                                           
 For global max and min values:  sumax < segy_data               
 For local and global max and min values:  sumax < segy_data verbose=1 
 To plot values specified by mode:                         
    sumax < segy_data output=binary mode=modeval | xgraph n=npairs     
 To plot seismic data with the only values nonzero being those specified
 by mode=modeval:                                    
    sumax < segy_data output=segy mode=modeval | suxwigb         

 Note:      while traces are counted from 1, sample values are counted from 0.
      Also, if multiple min, max, or abs max values exist on a trace,  
       only the first one is captured.                           

 See also: suxmax, supsmax                                 

 Credits:
      CWP : John Stockwell (total rewrite)
      based on an original program by:
      SEP: Shuki Ronen
      CWP: Jack K. Cohen

 Trace header fields accessed: ns