Re: Problem with plotting pressure latitude contours

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue Jun 05 2012 - 04:23:18 MDT

Soumik,

In order for gsn_csm_pres_hgt to work, the "units" attribute of your level coordinate array must be set to one of the allowable units (that are listed in your error message).

If you add the line:

  printVarSummary(ce_avg&lev_p)

it will show you what the units are, or if there's even a units attribute. If there isn't, you can fix this with:

  ce_avg&lev_p@units = "mb"

--Mary

On Jun 5, 2012, at 1:18 AM, Soumik Basu wrote:

> Hi,
>
> I have a variable which is from a CAM output and I interpolated it to
> certain pressure levels. lev_p is from 1000mb to 100mb.
>
> Variable: ce_avg
> Type: float
> Total Size: 9728 bytes
> 2432 values
> Number of Dimensions: 2
> Dimensions and sizes: [lev_p | 19] x [lat | 128]
> Coordinates:
> lev_p: [1000..100]
> lat: [-88.92773535229591..88.92773535229591]
> Number Of Attributes: 2
> _FillValue : -999
>
>
>
> But when I am trying to plot a vertical cross section using
> "gsn_csm_pres_hgt" I am getting this error message:
>
> (0) gsn_csm_pres_hgt: Fatal: The coordinate array for the first
> dimension of the input data must be in Pascals, Hecto-pascals, or
> millibars
> (0) and it must contain the attribute 'units' set to one of the
> following strings (depending on your units):
> (0) 'mb' 'Mb' 'MB' 'millibar' 'millibars' 'MILLIBARS'
> 'hybrid_sigma_pressure' 'Pa' 'pa' 'PA' 'Pascals' 'pascals' 'PASCALS'
> 'hpa' 'hPa' 'HPA' 'hecto-pascals' 'HECTO-PASCALS'
> (0) Cannot create plot.
> fatal:Illegal right-hand side type for assignment
>
> My variable is in pressure coordinate after the interpolation. I could
> not understand why still I am getting this error. Can anybody please
> help me.
>
> Thanks,
> Soumik
> --
> "Numbing the pain for a while will make it worse when you finally feel
> it.
> ~J.K. Rowling"
> *****************************************
> Soumik Basu
> Graduate Student, Research Assistant
> International Arctic Research Center
> University of Alaska Fairbanks
> Fairbanks,Alaska,USA
> *****************************************
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Jun 5 04:23:31 2012

This archive was generated by hypermail 2.1.8 : Wed Jun 06 2012 - 15:17:44 MDT