Making BIG images

From: Don Morton <morton_at_nyahnyahspammersnyahnyah>
Date: Tue, 02 Jun 2009 12:32:00 -0800


I'm sure this must be trivial, and perhaps not an NCL issue, but the
solution has eluded me.

I'm posting some forecast graphics to the web, and users would like them
to be larger, but without a sacrifice in resolution. To date, I've been
able to use gsnPaperWidth and gsnPaperHeight resources to accomplish
this, but I end up with only a portion of the image - it seems like my
viewing device wants to continue treating the image as if it were being
displayed on 8.5" x 11.0" media.

I've reduced the problem to a very simple script (see below). I run the
script to produce "" and when I view it using "gs" or "gv" it only
shows me the left bottom section. However, by playing with page sizes
in "gv" I can get more or less of the image. So, I suspect that NCL is
probably doing what it should, and that my problems stem from my
ignorance in dealing with different media types.

Once I get "" I try to use ImageMagick to convert to GIF

convert Big.jpg

but Big.jpg ends up, again, being only a partial image.

Is there something I should be setting in NCL, or are there a set of
flags I should use with "convert" to ultimately get the full, but
bigger, image in GIF or PNG format?

Thanks for any help. My simplified script follows:

; Include files
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"


   wrfoutFile =
; Full path to the wrfout file

  f = addfile(wrfoutFile,"r") ; Opens the netCDF file

  wks = gsn_open_wks("ps", "Big") ; Open a workstation for plotting

  gsn_define_colormap(wks,"WhViBlGrYeOrReWh") ; Define the colormap

  ;;;;;;;;;;;;;; Temperature plot ;;;;;;;;;;;;;;;

  tc = wrf_user_getvar(f, "tc", 0) ; T in deg C
  tc2d = tc(0,:,:)

  res = True
  res_at_gsnMaximize = True ; Maximize size of plot
  res_at_gsnPaperOrientation = "auto"
  res_at_gsnPaperWidth = 17.0
  res_at_gsnPaperHeight = 22.0

  plot = gsn_contour(wks, tc2d, res) ; Plot the data


ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
Received on Tue Jun 02 2009 - 14:32:00 MDT

This archive was generated by hypermail 2.2.0 : Wed Jun 03 2009 - 12:52:48 MDT