Re: gsn_csm_lat_time

From: David Brown <dbrown_at_nyahnyahspammersnyahnyah>
Date: Fri Nov 01 2013 - 11:48:35 MDT

Hi Ahmad,
The error message is telling you what the problem is -- you are creating a non-monotonic time dimension which is not allowed for a contour plot (and for most purposes in NCL):
Look at your print of the coordinate variable: between element 183 and 184 the value goes from 364 to 0.
I am not exactly sure what you are trying to do. Presumably this is a daily output file. Does it start in July? Why not use the time coordinate that is in the file?
 -dave

On Nov 1, 2013, at 9:18 AM, Ahmad Farsyud <a.farsyud@gmail.com> wrote:

> Hallo,
>
> My codes always produced these errors once I want to plot my data using a plotting function "gsn_csm_lat_time" for a panel plot.
>
> warning:ScalarFieldSetValues: irregular coordinate array sfXArray non-monotonic: defaulting sfXArray
> warning:ScalarFieldSetValues: irregular coordinate array sfXArray non-monotonic: defaulting sfXArray
> warning:ScalarFieldSetValues: irregular coordinate array sfXArray non-monotonic: defaulting sfXArray
> warning:ScalarFieldSetValues: irregular coordinate array sfXArray non-monotonic: defaulting sfXArray
>
> netcdf amp.obs.climo {
> dimensions:
> x = 2 ;
> lat = 37 ;
> level = 23 ;
> time = UNLIMITED ; // (365 currently)
> variables:
> double lat(lat) ;
> lat:standard_name = "grid_latitude" ;
> lat:long_name = "latitude" ;
> lat:units = "degrees_north" ;
> lat:axis = "Y" ;
> float level(level) ;
> level:standard_name = "air_pressure" ;
> level:long_name = "Pressure" ;
> level:units = "mb" ;
> level:positive = "down" ;
> level:axis = "Z" ;
> double time(time) ;
> time:standard_name = "time" ;
> time:units = "hours since 1958-01-01 00:00:00" ;
> time:calendar = "proleptic_gregorian" ;
> float amp(time, level, lat, x) ;
>
> yet i could not find what exactly the problem, everything seems OK for me.
>
> iJASOND = ispan(182,365,1)-1
> iJFMAMJ = ispan( 1, 181,1)-1
>
> niJASOND = dimsizes(iJASOND)
> niJFMAMJ = dimsizes(iJFMAMJ)
>
> i_NDJFM = new( niJASOND+niJFMAMJ, "integer","No_FillValue")
>
> i_NDJFM(0:niJASOND-1) = iJASOND
> i_NDJFM(niJASOND: ) = iJFMAMJ
> print(i_NDJFM)
>
> obsx = obs(lat|:,level|:,x|:,time|i_NDJFM)
>
> Thank you.
> _______________________________________________
> 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 Fri Nov 1 11:48:45 2013

This archive was generated by hypermail 2.1.8 : Mon Nov 11 2013 - 09:45:34 MST