Hello,
I have a GRIB data where the unit of time is "hours since 1800-01-01 00:00".
I have converted this to a UT-referenced date using the function ut_calendar
.When I plot this using * gsn_csm_pres_hgt, *I am getting the plot with time
in the x axis in "hours since 1800-01-01 00:00" unit.  How do I change this
to UT-referenced data?
Thanks & Regards,
Satheesan
The summary of the data gives
Variable: x
Type: float
Total Size: 286704000 bytes
            71676000 values
Number of Dimensions: 4
Dimensions and sizes:    [initial_time0_hours | 44] x [lv_ISBL1 | 25] x
[g0_lat_2 | 181] x [g0_lon_3 | 360]
Coordinates:
            initial_time0_hours: [1823664..1823922]
            lv_ISBL1: [1..1000]
            g0_lat_2: [90..-90]
            g0_lon_3: [ 0..359]
Number Of Attributes: 10
  center :    European Center for Medium-Range Weather Forecasts - Reading
  long_name :    Temperature
  units :    K
  _FillValue :    -999
  level_indicator :    100
  gds_grid_type :    0
  parameter_table_version :    128
  parameter_number :    130
  forecast_time :    0
  forecast_time_units :    hours
My code is like this
--------------------------------------------------------------------------------------------------
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
begin
f     = addfile ("temperature.grb", "r")
v     = f->T_GDS0_ISBL
    v!0    = "time"
    v!1    = "levl"
    v!2    = "lat"
    v!3    = "lon"
  time     = f->initial_time0_hours
  TIME    = ut_calendar(time,-3)
  delete(v&time)
  v&time = TIME
    v1=v(:,:,{-73},{347})
    v2=v1(levl|:,time|:)
  wks   = gsn_open_wks ("eps", "w-mara")
  gsn_define_colormap(wks,"cosam12")
  res                      = True
  res_at_cnFillOn                               = True
  res_at_cnLinesOn                            = False
  res_at_lbLabelAutoStride                = True
  res_at_tmYRTickSpacingF              = 1
  res_at_cnLevelSelectionMode         = "ExplicitLevels"
  res_at_cnLevels                               = fspan(220,270,9)
  res_at_cnFillColors                         = (/2,4,5,7,8,9,10,12,11,13/)
  plot = gsn_csm_pres_hgt (wks,v2,res)
end
-------------------------------------------------------------------
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Aug 04 2008 - 09:57:06 MDT
This archive was generated by hypermail 2.2.0 : Wed Aug 06 2008 - 07:03:04 MDT