* +-======-+ * Copyright (c) 2003-2007 United States Government as represented by * the Admistrator of the National Aeronautics and Space Administration. * All Rights Reserved. * * THIS OPEN SOURCE AGREEMENT ("AGREEMENT") DEFINES THE RIGHTS OF USE, * REPRODUCTION, DISTRIBUTION, MODIFICATION AND REDISTRIBUTION OF CERTAIN * COMPUTER SOFTWARE ORIGINALLY RELEASED BY THE UNITED STATES GOVERNMENT AS * REPRESENTED BY THE GOVERNMENT AGENCY LISTED BELOW ("GOVERNMENT AGENCY"). * THE UNITED STATES GOVERNMENT, AS REPRESENTED BY GOVERNMENT AGENCY, IS AN * INTENDED THIRD-PARTY BENEFICIARY OF ALL SUBSEQUENT DISTRIBUTIONS OR * REDISTRIBUTIONS OF THE SUBJECT SOFTWARE. ANYONE WHO USES, REPRODUCES, * DISTRIBUTES, MODIFIES OR REDISTRIBUTES THE SUBJECT SOFTWARE, AS DEFINED * HEREIN, OR ANY PART THEREOF, IS, BY THAT ACTION, ACCEPTING IN FULL THE * RESPONSIBILITIES AND OBLIGATIONS CONTAINED IN THIS AGREEMENT. * * Government Agency: National Aeronautics and Space Administration * Government Agency Original Software Designation: GSC-15354-1 * Government Agency Original Software Title: GEOS-5 GCM Modeling Software * User Registration Requested. Please Visit http://opensource.gsfc.nasa.gov * Government Agency Point of Contact for Original Software: * Dale Hithon, SRA Assistant, (301) 286-2691 * * +-======-+ function vpage (args) ************************************************************* ***** ***** ***** Usage: vpage xloc yloc xmax ymax ***** ***** ***** ************************************************************* xloc = subwrd(args,1) yloc = subwrd(args,2) xmax = subwrd(args,3) ymax = subwrd(args,4) ytop = subwrd(args,5) if( ytop = "" ) ytop = 0.5 endif 'set vpage off' 'getinfo page' pagex = subwrd(result,1) pagey = subwrd(result,2)-ytop 'set mproj latlon' *'set mproj scaled' *diff = (pagex-pagey/1.75)*0.5 *pagex = pagey/1.65 dx = pagex/xmax dy = pagey/ymax x1 = (xloc-1)*dx x2 = (xloc-0)*dx y2 = pagey - (yloc-1)*dy y1 = pagey - (yloc-0)*dy if( x1 < 0 ) x1 = 0 endif if( y1 < 0 ) y1 = 0 endif if( x2 > pagex ) x2 = pagex endif if( y2 > pagey ) y2 = pagey endif say 'vpage 'x1' 'x2' 'y1' 'y2 'set vpage 'x1' 'x2' 'y1' 'y2 'set grads off'