Hello all,
I am plotting some data using gsn_csm_xy and would like to add legend
to the plot. Below is the related resources I set for this purpose:
; add a legend
res@pmLegendDisplayMode = "Always" ; turn on legend
res@pmLegendSide = "Right" ; Change location of
res@pmLegendOrthogonalPosF = -0.15 ; more neg = down
res@pmLegendWidthF = 0.12 ; Change width and
res@pmLegendHeightF = 0.25 ; height of legend.
res@lgLabelFontHeightF = .02 ; change font height
res@lgPerimOn = False ; no box around
; labels for the legend
res@xyExplicitLegendLabels = (/"RN","SH","LH","Ground"/)
However, in the output plot, the legend labels were automatically
sorted alphabetically, i.e., "Ground", "LH", "SH", "RN". This is not
what I want. I need the legend appears in the original order I
provided Anyone can provide some idea how to achieve this? Many
thanks.
Regards,
Xianxiang
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Jan 4 21:42:04 2011
This archive was generated by hypermail 2.1.8 : Thu Jan 13 2011 - 09:24:21 MST