Hi Gina,
Reset the time coordinate variables to run from 0->5
months = (/ 10, 11, 0, 1, 2, 3 /)   ; November to April
rotated = pacav( months , : )
rotated&time = ispan(0,5,1)
and then explicitly set the axis labels, as is shown in tickmarks 
example 2 where the x-axis labels are manually set:
http://www.ncl.ucar.edu/Applications/tickmarks.shtml#ex2
Adam
Gina Henderson wrote:
> Hi there,
> 
> thanks for your response. I reordered the array and it is plotting but I 
> am getting a warning because my y values are not increasing?
> 
> warning:ScalarFieldSetValues: irregular coordinate array sfYArray 
> non-monotonic: defaulting sfYArray
> 
> and this is then stopping me from labeling the y axis.  Is there any way 
> to get around this?
> 
> Thanks, Gina.
> 
> 
> 
> 
> On Tue, Mar 10, 2009 at 3:54 PM, Dave Allured <dave.allured_at_noaa.gov 
> <mailto:dave.allured_at_noaa.gov>> wrote:
> 
>     Gina,
> 
>     Try making a second array variable that is a reordered subset of
>     pacav.  Use vector subscripting to get the subset and the order you
>     want.  Something like this (untested):
> 
>        months = (/ 10, 11, 0, 1, 2, 3 /)   ; November to April
>        rotated = pacav( months , : )
>        plot = gsn_csm_hov (wks, rotated, res)
> 
>     This should also carry over the correct reordered coordinates and
>     attributes.  HTH.
> 
>     Vector subscripting is documented here:
>     http://www.ncl.ucar.edu/Document/Manuals/Ref_Manual/NclVariables.shtml#Subscripts
> 
>     "There is more than one way to do this."   ;-)
> 
>     Dave Allured
>     CU/CIRES Climate Diagnostics Center (CDC)
>     http://cires.colorado.edu/science/centers/cdc/
>     NOAA/ESRL/PSD
>     <http://cires.colorado.edu/science/centers/cdc/%0ANOAA/ESRL/PSD>,
>     Climate Analysis Branch (CAB)
>     http://www.cdc.noaa.gov/psd1/
> 
>     Gina Henderson wrote:
>      > Hi there,
>      >
>      > I am plotting a zonal average using the gsn_csm_hov function and
>     have a
>      > question regarding the time dimension of my array. My plotting array
>      > looks like: plot = gsn_csm_hov(wks, pacav( : , : ),res) where the
>     first
>      > dimension is months 0:11 and the second is longitude. However I
>     want to
>      > only plot months 11(nov) through 3(apr). Is there any way to
>     index this?
>      >
>      > Thanks, Gina.
>      >
>      >
>      >
>     ------------------------------------------------------------------------
>      >
>      > _______________________________________________
>      > 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
> 
> 
> 
> 
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
-- -------------------------------------------------------------- Adam Phillips asphilli_at_ucar.edu National Center for Atmospheric Research tel: (303) 497-1726 ESSL/CGD/CAS fax: (303) 497-1333 P.O. Box 3000 Boulder, CO 80307-3000 http://www.cgd.ucar.edu/cas/asphilli _______________________________________________ ncl-talk mailing list List instructions, subscriber options, unsubscribe: http://mailman.ucar.edu/mailman/listinfo/ncl-talkReceived on Tue Mar 10 2009 - 15:35:53 MDT
This archive was generated by hypermail 2.2.0 : Thu Mar 12 2009 - 14:10:21 MDT