A package to generate Postscript plots with IDL
Developer Documentation

.
singlecontour.pro

Last modification date:
Sat May 11 11:42:47 2013
Statistics:
621 lines of code

SINGLECONTOUR

procedure SINGLECONTOUR, psname, v1, [BACKGROUND=byte array], [XAXISL=structure], [YAXISL=structure], [XAXISU=structure], [YAXISU=structure], [PLOT=structure], [CFILE=structure], [LEGEND=structure], [/SPANISH], [PREEXTERNAL=string array], [EXTERNAL=string array], [QUIET=QUIET], [IN=structure], [OUT=variable], [VAR=structure], [ENTRANCE=integer], [EXIT=integer], [_EXTRA=string]

SINGLECONTOUR generates a Postscript 1-D contour plot. See the full procedure

Examples
  A simple call to SINGLECONTOUR is:
    x    = -50. + FINDGEN(101)
    y    = 100. + FINDGEN(51)
    xx   = x # (1.+FLTARR(51))
    yy   = (1.+FLTARR(101)) # y
    f    = 5*(SIN(0.08*xx)*SIN(0.12*yy))^2+5*(SIN(0.05*(xx+yy)))^2 + 0.3*RANDOMN(seed,101,51)
    SINGLECONTOUR, "test10a.ps", {f:f}
  See the jmaplot tutorial for additional examples. 
Version
v. 3.1, 11 May 2013.
History
                                                        

  v0.1: The difference between xmin,xmax and ymin,ymax and yrange is     
         introduced.                                                     
        Variable step in xand y is allowed.                             
        LINESTYLE and EXTERNAL are introduced.                           
  v0.2: EXTXTICKS and EXTYTICKS are introduced.                          
  v1.0: General cleanup.                                                 
  v1.1: Axes which increase in the opposite direction allowed.           
  v1.2: BACKGROUND added.                                                
  v1.3: PSFONTS added.                                                   
  v2.0: English version.                                                 
  v2.1: IDLdoc documentation.
        CTABLE problems from MULTIGRAPH eliminated.                          
        Fix to the small font problem when using MULTIGRAPH (NPX).
  v2.2: OPENHTML introduced.
        Upgrade to IDLdoc documentation. 
        Contour color control transferred from CTEXT to C_COLORS.  
        Additional keywords can be passed to CONTOUR using _REF_EXTRA.
  v2.3: To ensure compatibility, use _EXTRA instead of _REF_EXTRA.
        Windows compatibility enhanced.
  v2.4: CELL_BLANK keyword added. 
  v2.5: Version system update.
        QUIET flag added.             
        REVERSE bug fixed.   
  v3.0: Global rewritting.
        Most KEYWORDS eliminated with input converted into structures.
        Assimilation to SINGLEPLOT changes.
        Legend types eliminated.
        New grid, thick, and linestyle options for axes.
        Colors for lines introduced.
        THICK and LINESTYLE added for the lines.
        MYDEVICE eliminated.     
        CMYK PS output added.
        HTML pages moved to local directory.
        TEST eliminated. 
 v3.1:  NOBORDER added to LEGEND.  
Author
Jesús Maíz Apellániz, IAA
Common blocks
vv
Statistics
Lines of code  621
McCabe Cyclomatic Complexity metric   156
McCabe Essential Complexity metric   5
McCabe Module Design Complexity metric   1

Parameters
psname
in, required
string
Postscript file name. If '' is passed, the Postscript file is neither opened nor closed (this option is intended to be used from MULTIGRAPH).
v1
in, required
structure
Data structure. Possible tags:
           F:         Function to be plotted (required).
           G:         Masking function.
           G_CRIT:    Masking critical value.
           G_CELL:    Flag for masking with CELL_FILL.
           X:         x values for f (and g).
           Y:         y values for f (and g).
           NOLINES:   Flag for not drawing contour lines.
           NOFILL:    Flag for not filling contours.
           C:         Contour values.         
           CN:        Number of contour values (superseded by c).         
           CMIN:      Value for minimum contour (superseded by c).         
           CMAX:      Value for maximum contour (superseded by c).         
           CLOG:      Flag for logarithmic spacing of contours (superseded by c).         
           COLOR:     Color index (fill if NOFILL not activated, contours otherwise).
           LINESTYLE: IDL line style.
           THICK:     Line thicknesses.  

Keywords
BACKGROUND
in, optional
byte array
Background image of dimensions (nx,ny) or (nx,ny,3).
XAXISL
in, optional
structure
Lower x-axis structure with the following possible tags:
           RANGE:     2-element float array with minimum and maximum.
           EXTRA:     If -1.0, it increases the x range by 10%. If not 1.0, it
                       increases the natural x range by that fraction. RANGE
                       supersedes it.
           STYLE:     Axis type, -2 (nothing), -1 (lines), 0 (lines and
                       ticks), and 1 (lines, ticks, and text). 
           TITLE:     Axis title.                       
           THICK:     Line thickness.                   
           LINESTYLE: Line style.                
           TICKNAME:  Text for the tick marks.            
           CHARSIZE:  Text size (also affected by PLOT.CHARSIZE).
           TICKV:     Values for the tick marks.            
           TICKLEN:   Scale factor for the tick lengths.
           LESSTICKS: Flag for using less tick marks (ignored if TICKV given).
           MORETICKS: Flag for using more tick marks (ignored if TICKV given).
           MINORN:    Number of minor tick marks per major ones, counting major 
                       ones as minor (ignored if LOG is activated). 
YAXISL
in, optional
structure
Lower y-axis structure. See XAXISL for the possible tags:
XAXISU
in, optional
structure
Upper x-axis structure. See XAXISL for the possible tags:
YAXISU
in, optional
structure
Upper y-axis structure. See XAXISL for the possible tags:
PLOT
in, optional
structure
Plot structure with the following possible tags:
           XSIZE:     X size (in normal coordinates) of the plot.
           YSIZE:     Y size (in normal coordinates) of the plot.
           XC:        X position (in normal coordinates) of the center of the plot.
           YC:        Y position (in normal coordinates) of the center of the plot.
           CHARSIZE:  Global text size.
           CHARTHICK: Global text thickness.
           PSASPECT:  Aspect ratio of the Postscript file.
           PSXSIZE:   X size (in cm) of the Postscript file.
           LANDSCAPE: Flag for landscape mode.
           FONT:      -1 (Vector-drawn), 0 (PS), 1 (TrueType).
           CMYK:      Flag to generate CMYK PS output.
           TITLE:     Main title.  
CFILE
in, optional
structure
Color table structure with the following possible tags:
           NAME:      File name.                                  
           DIR:       Directory name.                             
           TABLE:     Color table.                                
           DEF:       Default color. 
           WHITE:     White color. 
LEGEND
in, optional
structure
Legend structure with the following possible tags:
           DRAW:      Flag to to do legend (unnecesary if any other tag is
                       specified).
           CLEAR:     Flag to clear the legend background.
           XLEFT:     Left border of the legend box in plot-normalized
                       coordinates (default: 0.05).
           YDOWN:     Lower border of the legend box in plot-normalized
                       coordinates (default: 0.05).
           XSIZE:     Horizontal size of the legend box in plot-normalized
                       coordinates (default: 0.25).
           YSIZE:     Horizontal size of the legend box in plot-normalized
                       coordinates (default: 0.15). 
           NOBORDER:  Flag not to draw a border around the legend.
SPANISH
in, optional
boolean (def. FALSE)
Flag to use decimal commas instead of decimal points.
PREEXTERNAL
in, optional
string array
String(s) with commands to be executed before the plots are drawn.
EXTERNAL
in, optional
string array
String(s) with commands to be executed after the plots are drawn.
QUIET
in, optional
(def. FALSE)
Flag to supress informational messages.
IN
in, optional
structure
Input structure to pass the structures produced by out.
OUT
out, optional
variable
Output structure.
VAR
in, optional
structure
Input structure to pass additional variables.
ENTRANCE
in, optional
integer
Entrance point for sequential calls from MULTIGRAPH.
EXIT
in, optional
integer
Exit point for sequential calls from MULTIGRAPH.
_EXTRA
in, optional
string
As of IDL 6.3, the following additional keywords can be passed to CONTOUR here:
C_ANNOTATION
C_CHARSIZE
C_CHARTHICK
C_LABELS
C_ORIENTATION
C_SPACING
CLOSED
DOWNHILL
FOLLOW
MIN_VALUE
MAX_VALUE
PATH_DATA_COORDS
PATH_DOUBLE
PATH_INFO
PATH_XY
See the IDL manual for descriptions of these keywords. Also, note that not all of them have been tested with SINGLECONTOUR. If you encounter an error or detect an unexpected behavior while using them, please send me an e-mail.


Personal IDL library of Jesús Maíz Apellániz, Ramón y Cajal Fellow, Instituto de Astrofísica de Andalucía.
Feel free to contact me for more information about these routines or to submit a bug report or a feature request.

Produced by IDLdoc 1.6 beta on Fri Jun 28 22:22:44 2013