NAME

     grdimage - Create grayshaded or colored  image  from  a  2-D
     netCDF grd file


SYNOPSIS

     grdimage grdfile -Ccptfile -Jparameters [ -Btickinfo ]  [  -
     Edpi  ] [ -Fred/green/blue ] [ -Iintensfile] [ -K ] [ -M ] [
     - O  ]  [  - P  ]  [  - Rwest/east/south/north[r]  ]   [   -
     U[/dx/dy/][label]  ] [ -V  ] [ -Xx-shift ] [ -Yy-shift ] [ -
     ccopies ] [ -0 || -1 || -2 ]


DESCRIPTION

     grdimage reads a 2-D gridded file and produces a gray-shaded
     (or  colored) map by assigning each contour interval a gray-
     shade (or color).  Optionally, illumination may be added  by
     providing  a  file  with  intensities  in the (-1,+1) range.
     Values outside this range will be clipped.   Such  intensity
     files  can be created from the grdfile using grdgradient and
     modified by grdmath or grdhisteq.   Each  grid-node  in  the
     grdfile  is  represented  as a shaded (or colored) rectangle
     centered on the grid node.  When using map projections,  the
     grid is first resampled on a new rectangular grid  (This can
     be a time-consuming process for large grid files).  A 24-bit
     true  color  PostScript  file  is  output using one of three
     methods.  The region option can be  used  to  select  a  map
     region  larger or smaller than that implied by the extent of
     the grdfile.

     grdfile
          2-D gridded data set to be imaged

     -C    name of the color palette table

     -J    Selects the  map  projection.  Scale  is  inch/degree,
          1:xxxxx. or width in inch (upper case modifier).

          CYLINDRICAL PROJECTIONS:

          -Jclon0/lat0/scale (Cassini)
          -Jmscale (Mercator - Greenwich and Equator as origin)
          -Jmlon0/lat0/scale (Mercator - Give meridian and  stan-
          dard parallel)
          -Joalon0/lat0/azimuth/scale (Oblique Mercator  -  point
          and azimuth)
          -Joblon0/lat0/lon1/lat1/scale (Oblique Mercator  -  two
          points)
          -Joclon0/lat0/lonp/latp/scale (Oblique Mercator - point
          and pole)
          - Jqlon0/scale  (Equidistant   Cylindrical   Projection
          (Plate Carree))
          -Jtlon0/scale (TM - Transverse Mercator)
          -Juzone/scale (UTM - Universal Transverse Mercator)
          -Jylon0/lats/scale (Basic Cylindrical Projection)

          AZIMUTHAL PROJECTIONS:

          -Jalon0/lat0/scale (Lambert).
          -Jelon0/lat0/scale (Equidistant).
          -Jglon0/lat0/scale (Orthographic).
          -Jslon0/lat0/scale (General Stereographic)

          CONIC PROJECTIONS:

          -Jblon0/lat0/lat1/lat2/scale (Albers)
          -Jllon0/lat0/lat1/lat2/scale (Lambert)

          MISCELLANEOUS PROJECTIONS:

          -Jhlon0/scale (Hammer)
          -Jilon0/scale (Sinusoidal)
          -Jklon0/scale (Eckert VI)
          -Jnlon0/scale (Robinson)
          -Jrlon0/scale (Winkel Tripel)
          -Jwlon0/scale (Mollweide)

          NON-GEOGRAPHICAL PROJECTIONS:

          -Jpscale (Linear projection for polar (theta,r) coordi-
          nates)
          -Jxx-scale[l|ppow][/y-scale[l|ppow]] (Linear, log,  and
          power scaling)
          More details can be found in the psbasemap manpages.


OPTIONS

     No space between the option flag and  the  associated  argu-
     ments.

     -B    Sets map boundary tickmark  intervals.  See  psbasemap
          for details.

     -E    Sets the resolution of the projected grid that will be
          created if a map projection other than Linear or Merca-
          tor was selected.  By default, the projected grid  will
          be  of  the  same  size (rows and columns) as the input
          file.

     -F    Sets the color used for Frame and annotation. [Default
          is black]

     -I    Gives the name of a grdfile with  intensities  in  the
          (-1,+1) range. [Default is no illumination].

     -K    More PostScript code will be appended  later  [Default
          terminates the plot system].

     -M    Force conversion to monochrome image using the (telev-
          ision) YIQ transformation.

     -O    Selects Overlay plot mode [Default initializes  a  new
          plot system].

      - P    Selects  Portrait  plotting  mode  [GMT  Default  is
          Landscape, see gmtdefaults to change this].

     -R    west, east, south, and north  specify  the  Region  of
          interest.  To specify boundaries in degrees and minutes
          [and seconds], use the dd:mm[:ss] format.  Append r  if
          lower  left  and  upper right map coordinates are given
          instead of wesn.  You may  ask  for  a  larger  w/e/s/n
          region  to  have  more  room  between the image and the
          axes.  A smaller region than specified in  the  grdfile
          will  result in a subset of the grid [Default is region
          given by the grdfile].

     -U    Draw Unix System time stamp on plot.  User may specify
          where the lower left corner of the stamp should fall on
          the page relative to lower left corner of plot in  inch
          [Default   is  (-0.75,-0.75)].   Optionally,  append  a
          label, or c (which will plot the command string.)

     -V    Selects verbose mode, which will send progress reports
          to stderr [Default runs "silently"].

     -X -Y
          Shift  origin  of  plot   by   (x-shift,y-shift)   inch
          [Default is (1,1) for new plots, (0,0) for overlays].

     -c    Specifies the number of plot copies. [Default is 1]

     -0    Create the image using the Adobe PostScript colorimage
          operator.   This is the GMT default (which can be modi-
          fied in the .gmtdefaults file).

     -1    Create the  image  by  plotting  individually  colored
          tiles.

     -2    Create the image by color separation using three calls
          to image for later processing by psto24.


EXAMPLES

     To gray-shade the file hawaii_grav.grd with shades given  in
     shades.cpt  on  a  Lambert  map at 0.5 inch/degree along the
     standard parallels 18 and 24, and using 1 degree  tickmarks,
     try

     grdimage hawaii_grav.grd -Jl18/24/0.5 - Cshades.cpt  - B1  >
     hawaii_grav_image.ps
     To create an illuminated color PostScript plot of the  grid-
     ded  data  set  image.grd, using the intensities provided by
     the  file  intens.grd,  and  color  levels   in   the   file
     colors.cpt, with linear scaling at 10 inch/x-unit, tickmarks
     every 5 units, and using  color  separations  for  use  with
     psto24, try

     grdimage image.grd -Jx10 -Ccolors.cpt -Iintens.grd -B5 -2  >
     image.ps


BUGS

     Having three separate ways of creating the colorimage  comes
     from  the  fact  that  many different implementations of the
     colorimage PostScript operator exists for a wide variety  of
     hardcopy devices.  The three options allow you to create the
     type of output required by your RIP.


SEE ALSO

     gmt, grdcontour, grdview,  grdgradient,  grdhisteq,  ps2ras,
     psto24


REFERENCES

     Wessel, P., and W. H. F. Smith, 1995,  The  Generic  Mapping
     Tools  (GMT)  version  3.0  Technical  Reference & Cookbook,
     SOEST/NOAA.
     Wessel, P., and W. H. F. Smith, 1995,  New  Version  of  the
     Generic Mapping Tools Released, EOS Trans. AGU, 76, p. 329.
     Wessel, P., and W. H. F. Smith, 1995,  New  Version  of  the
     Generic           Mapping           Tools          Released,
     http://www.agu.org/eos_elec/95154e.html, Copyright  1995  by
     the American Geophysical Union.
     Wessel, P., and W. H. F. Smith, 1991,  Free  Software  Helps
     Map and Display Data, EOS Trans. AGU, 72, p. 441.