Re: reversing the legend

From: Mary Haley (haley AT XXXXXX)
Date: Wed Feb 05 2003 - 15:55:16 MST

> Hi there -
> It seems that legends in an XY plot are in a reverse order from what I would call intuitive. That is, the 0th Y datum "vector" is the last legend item while the Nth Y datum is the first. For example, if I use:
> Y = some 2-D array with the first dimension 3
> res@xyExplicitLegendLabels = (/"0","1","2"/)
> res@xyDashPatterns = (/0,1,2/)
> plot = gsn_xy(wks,Xaxis,Y,res)
> then the datum Y(0,:) is plotted with a solid line and label "0", but it is the last item in the legend whereas I want it to be the first.
> This can of course be avoided by just reversing everything, but that's a pain in the neck. I feel I am missing something easy here, but does anyone know of an easy way to reverse the legend?
> Cheers,
> Josh

Hi Josh,

I'm afraid there's no easy way to reverse the legend, as you
discovered. I'll find out from the developers if this is an easy
feature to add.


ncl-talk mailing list
ncl-talk AT

This archive was generated by hypermail 2b29 : Wed Feb 05 2003 - 17:26:34 MST