Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 
Previous: GEMPAK Mapping Programs Next: GEMPAK Mapping Programs: SNMAP & GDMAP Table of contents Frames User Manual GEMPAK Online Tutorial > GEMPAK Mapping Programs

6.0 GEMPAK Mapping Programs: SFMAP
SFMAP plots any parameters which can be derived from the data in a GEMPAK surface data file.

First, lets start up SFMAP and read in the defaults file:

prompt% sfmap

   GEMAPAK-SFMAP>restore defaults/sfmap.nts 
>Now, display the user interface:
GEMPAK-SFMAP>dis
AREA      Data area                         
GAREA     Graphics area                     
SFPARM    Surface parameter list            skyc;tmpf;wsym;rmsl;ptnd;dwpf;p03i;brbk:.7:2
DATTIM    Date/time                         
SFFILE    Surface data file                 
COLORS    Color list                        1;2;3;25;5;6;7;9
MAP       Map color/dash/width              3/1/1
LATLON    Line color/dash/width/label/inc   0
TITLE     Title color/line/title            1/-2
CLEAR     Clear screen flag                 YES
PANEL     Panel location/color/dash/width   0
DEVICE    Graphics device                   xw
PROJ      Map projection/angles/margins     nps
FILTER    Filter data factor                yes
TEXT      Text size/font/width/hw flag      1.3/23//HW
SKPMIS    Skip missing data flag            no
CLRBAR    Color/ornt/anch/x;y/ln;wd/freq
GEMPAK-SFMAP>

Old Variables (already seen in SFLIST, SNLIST, GDLIST)

New Variables:

Okay, of the variables used in SFMAP, only AREA, GAREA, DATTIM, and SFFILE need to be set. The rest are set to default values. We already know about DATTIM, SFFILE and AREA from our work with SFLIST. Of the remaining new variables, lets start with GAREA.

  1. GAREA-- Graphics Area

    Help: So, what's the difference between the GAREA and AREA?

    ANSWER: By definition, GAREA is the graphics area, meaning the part of the map that will be plotted. AREA is the data area, meaning the area from which to select the data to plot. Less obvious, is why GEMPAK separates the two:

    Sometimes you might want separate control over the region of the map that is plotted, and the region that is covered by data.

    Tip:A practical example of this is, when you want to plot a map with complete data coverage, including the edges, you should make AREA bigger than GAREA. This can be done by adding a minus "-" to AREA or an asterisk "*" to GAREA:

       AREA = CO-      or     AREA = WV
       GAREA = CO             GAREA = WV*
    

    GAREA can be specified in some of the same ways as AREA:

    1. lat/lon bounds
    2. station (you get the area centered around the station)
    3. geographic abbreviation from $GEMTBL/stns/geog.tbl

    Warning:You cannot use the @ symbol to specify GAREA.

    Why not? Because GAREA defines the boundaries of the graph. Adding an "@" would force an irregular boundary for the graph. Think of the "@" sign as a way to restrict the selection of data.

    The rest of these variables are currently set to defaults by the sfmap.nts file. However, it's a good idea to know how they work, so that later you can change them if you need to.

  2. PROJ - Map Projection

    The map projection directly affects the way the map looks on the screen. Think about the way the continental US looks in the Mercator projection versus the Polar Stereographic projection.

    The projection can be specified as a simple map projection, or as a full map projection. Without getting into much detail, specifying a map projection in general usually requires a set of angles. Through the PROJ variable and these angles, in combination with the GAREA variable, you have the flexibility to generate a very specific map projection from within GEMPAK. A full map projection in GEMPAK looks like this:

    PROJ = STR/90;-100;0
    

    We know from looking at the phelp proj help file that

    GEMPAK-SFMAP>ph proj
    
    ...
         The following full map projections may also be specified:
    
            MER     (CYL)   Mercator
            MCD     (CYL)   Modified Cylindrical Equidistant
            STR     (AZM)   Polar Stereographic
    ...
    
         In addition, three angles MUST be specified in PROJ.  The angles 
         have the following meanings for the different projection classes:
    
            CYL     The angles are not used.  A default value for angle2, 
                    polon is used.
    
            AZM     angle1 -- latitude of the projection's point of tangency.
                    angle2 -- longitude of the projection's point of tangency.
                    angle3 -- not used.
    ...
    
    STR is the Polar Stereographic projection. We see that it belongs to the (AZM) family. That means it's an azimuthal projection. For an azimuthal projection, you must specify two angles. Although the third angle is not used, GEMPAK still expects to see a 0 in its place.

    The first angle is the standard latitude through which the projection plane passes. The second angle is the central longitude. This is the longitude that lies parallel to the grid columns. For a view of North America, STR/90;-100;0 is a good choice.

    If this seems a little complicated, you're right, it is. Often you will find that you don't need to specifiy the full map projection. GEMPAK comes equiped with a few simple map projections that will work with standard graphical areas (mostly over the US). From the phelp proj help file, they are:

         The following simple map projections may be specified:
    
            MER     Mercator
            NPS     North Polar Stereographic
            SPS     South Polar Stereographic
            LCC     Northern Hemisphere Lambert Conic Conformal
            SCC     Southern Hemisphere Lambert Conic Conformal
            CED     Cylindrical Equidistant
            MCD     Modified Cylindrical Equidistant
            UTM     Universal Transverse Mercator
            NOR     North Orthographic 
            SOR     South Orthographic 
    
    

    To use a simple map projection, simply ask for it:

       PROJ = NPS 
    
    

    Here's an example of the NPS simple map projection. The NPS specification is really just an abbreviation for the full map projection STR/90;-90;0. It looks good over the US, but it won't work well for viewing Africa. For that you'll need to use a full map projection. This is true of all simple map projections.

  3. DEVICE - Device Driver

    We talked a little about device drivers back in the Introduction to GEMPAK chapter. Since we are going to create a picture, we need to tell GEMPAK how to show us the picture. The default is set to XW (X-Window). This will cause a window to be opened on your screen, and then the graphic will be drawn to it. There are other ways to view your picture, and they each have their own device drivers. We'll discuss them later in the Device Drivers section.

  4. CLEAR

    Each time GEMPAK draws a new map or graph to the X-Window, you have the option of first clearing the screen. When CLEAR=YES, whatever is currently in the X-Window (if anything) is wiped away, and the new graphic is drawn on a blank screen. If CLEAR=NO, then the screen is not cleared first, and the new graphic plots on top of the existing graphic. This is how overlays are constructed in GEMPAK. In fact, the screen will not clear even if you exit the current GEMPAK program and start another. This is because of the multiple process design of GEMPAK. For more information on why this works, see the Introduction to GEMPAK chapter.

    We will practice creating overlays later. For now, lets just keep CLEAR=YES.


Map Aesthetics

The other new variables (COLORS, MAP, LATLON, TITLE, PANEL, FILTER, TEXT) control the way the graphic looks, including the colors, line thicknesses, text font's, etc. We call these Map Aesthetics. While these variables can help you generate very specific looking graphics, learning about all the things each of them do can be overwhelming. For now, it's best to use the default values. Later you can learn how to configure them for yourself.

They are described in their own section: Map Aesthetics


Let's try it... Exercises:Practice Exercises!!

  1. Plot a standard surface chart for CO area for 12 UTC on August 19, 1991. (Hint: use the Hurricane Bob data)

    Tip:The parameter's position in SFPARM corresponds to placement around station (except for wind barbs which are always centered on the station)...

    For Example if:

    sfparm= skyc; tmpf; wsym; rmsl

    The parameter's position will correspond to this position chart:

      
                    18      14      8       16      22
                    19      2       10      4       23
                    12      3       1       5       13
                    20      6       11      7       24
                    21      15      9       17      25
    

    SKYC goes in position 1, TMPF in position 2, WSYM in position 3, and RMSL in position 4.

    Help:Why in that order?

    ANSWER: The numbered positions correspond to the standard ordering of data on a surface chart.

    BACK TO THE PRACTICE EXERCISE: In case you're not a met student, a standard surface chart is arranged more or less like so:

    TMPF-upperleft, skyc&brbk--middle, rmsl--upperright,wsym--middleleft, DWPT--lowerleft, po3i--lowerright, ptnd--middleright

    The GEMPAK four letter sfparm abbreviations would therefore be:

                          
                      TMPF            RMSL 
                      WSYM    SKYC    PTND
                      DWPF    & BRBK  P03I
    
    
    

    So, the SFPARM setting from the default file is already set for a standard surface chart. All that remains is to set the other variables. View answer:


$MAPFIL - Defines map file

You won't find this variable on any user interface, it is a hidden variable.

The default map is a medium resolution, political boundary map of the world. You can choose an alternate map from the available GEMPAK map data base using $MAPFIL. These maps can be especially useful in overlays to add detail to a GEMPAK map, in order to show more political boundaries, add lakes, or even plate tectonics.

The higher the resolution of the map, the longer it takes to draw. For global maps, low resolution is fine. For small scale maps, high resolution can make an impressive graphic.

GEMPAK "remembers" last map file used. The default is HIPOWO.CIA.

Let's try it... Exercises:Practice Exercises!!

Let's plot a chart over North America, using a coastal boundary map.

  1. Use Hurricane Bob data for 0 UTC data on August 20,1991.
  2. Choose a low resolution coastal boundary map $MAPFIL=LOCONH.GSF
  3. Plot sky cover, temperature, and dew point: Put SKYC in position 1, TMPC in position 2 and DWPT in position 7:
    sfparm=skyc;tmpc;blnk;blnk;blnk;blnk;dwpc
    
    or
    sfparm=barb;tmpc;;;;;dwpc
    
  4. Use full map projection (Remember, you can't abbreviate with a non-standard area)

    PROJ = STR/90;-100;0

  5. AREA and GAREA set for North America:

    AREA=dset GAREA=10;-125;50;-20

  6. When you're done, be sure to set $MAPFIL back to default hipowo.cia aka: base

    Answer:

 


Previous: GEMPAK Mapping Programs Next: GEMPAK Mapping Programs: SNMAP & GDMAP Table of contents Frames User Manual GEMPAK Online Tutorial > GEMPAK Mapping Programs

 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690