histogram problem

From: David Adams <dave.k.adams_at_nyahnyahspammersnyahnyah>
Date: Sun Feb 24 2013 - 20:28:36 MST

Hi all,
I am try to create histogram of number of convective events for each month
of the year.
The input file is simply the integer value of the day of the year for the
reported convective event. However, the plots are incorrect.
My version of ncl is NCAR Command Language Version 6.0.0
Any suggestions?

Dave Adams

; test.ncl
; This ncl program reads in integer days of the year
; for for convective events to make a
; histogram of monthly convective events.

load "/usr/local/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "/usr/local/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
load "/usr/local/lib/ncarg/nclscripts/csm/contributed.ncl"
load "/$NCARG_ROOT/lib/ncarg/nclscripts/csm/shea_util.ncl"

ncol1 = 1
nlvl = 278

seasonal_data =
asciiread("Seasonal_dates_convective_events.dat",(/nlvl,ncol1/), "integer")
day = seasonal_data(:,0)

wks = gsn_open_wks("pdf", "Time_local_hour_event_histogram")

  res = True
  res@gsnDraw = False
  res@gsnFrame = False

  res@gsnHistogramDiscreteBinValues = ispan(30,360,30)

   plot = gsn_histogram(wks,day,res)


  res@tmXBMode = "Explicit" ; Define tick mark labels.
  res@tmXBValues = plot@MidBarLocs
  res@tmXBLabels = (/"J","F","M","A","M","J","J","A","S","O","N","D"/)
  plot=gsn_histogram(wks,day,res) ; create histogram


ncl-talk mailing list
List instructions, subscriber options, unsubscribe:

Received on Sun Feb 24 20:28:47 2013

This archive was generated by hypermail 2.1.8 : Thu Feb 28 2013 - 14:47:31 MST