Re: Strange Legend

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Fri Dec 07 2012 - 13:23:35 MST

Dear Guilherme,

Adam already gave you some good pointers. I just wanted to point out that the gsn_csm_xy3 code wasn't set up to try to handle multiple legends. Once you start attaching plot onto plot, it becomes an issue of where you want the legends.

If you read the documentation for gsn_csm_xy3, it recommends to use "gsn_create_legend" to create your own legend.

http://www.ncl.ucar.edu/Document/Graphics/Interfaces/gsn_csm_xy3.shtml

As the documentation suggests, see the third frame of xy_19.ncl at:

http://www.ncl.ucar.edu/Applications/xy.shtml#ex19

--Mary

On Dec 6, 2012, at 3:45 PM, Adam Phillips wrote:

> Hi Guilherme,
> Thanks for sending along a simple script+data illustrating the issue. This to me looks like a bug. It is coming into play when you attempt to draw the legend for the 3rd timeseries. If you set resR2@pmLegendDisplayMode = "NoCreate" (the default), you see the incorrect legend on the right hand side disappear. NCL seems to be taking the name of the workstation and creating a legend item, which is quite weird. A NCL developer will need to investigate.
>
> The work around: Turn off the legend in the resR2 resource list as I describe above, and draw the 3rd item in the legend manually. I've modified your code to do this and have attached it and the resulting .png here. (I followed what was done in legend example #8 here:
> http://www.ncl.ucar.edu/Applications/legend.shtml#ex8
>
> Hope that helps.. Adam
>
>
> On 12/6/12 2:15 PM, Guilherme Martins wrote:
>> Hello users,
>>
>> When I plot my figure I saw that appear a text or legend on the right side. How can I remove it? The figure and my script is in attach.
>>
>> Thanks,
>>
>> Guilherme.
>>
>> --
>> Guilherme Martins
>> http://guilhermemartins.hd1.com.br/
>>
>>
>>
>>
>>
>> _______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>>
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
> <CLA-CAPE-NCL_media_guilherme.ncl><test.png>_______________________________________________
> 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 Dec 7 13:23:45 2012

This archive was generated by hypermail 2.1.8 : Fri Dec 07 2012 - 13:30:06 MST