Fwd: assigning array indexes using gsn_csm_hov

From: Gina Henderson <ginah_at_nyahnyahspammersnyahnyah>
Date: Tue, 10 Mar 2009 16:39:02 -0400

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> 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
Received on Tue Mar 10 2009 - 14:39:02 MDT

This archive was generated by hypermail 2.2.0 : Thu Mar 12 2009 - 14:10:21 MDT