[ncl-talk] Label Bar Label Missing
Barry Lynn
barry.h.lynn at gmail.com
Wed Apr 19 00:43:47 MDT 2017
Hi:
I was able to make the change suggested, but when I read in the data and
process it first (instead of starting with a ready made file), the first
panel is larger than the rest.
I assume this is another "bug" in the WRF settings...
This doesn't happen when I supply the output as a ready to read file.
Barry
On Tue, Apr 11, 2017 at 8:55 PM, Adam Phillips <asphilli at ucar.edu> wrote:
> Hi Barry,
> Thanks for providing an easy-to-run script as that made debugging this
> much easier. It turns out that the solution is simply a matter of providing
> a units attribute for the data array (liq_equiv_sml) that you are passing
> to wrf_contour at line 279.
> Thus, append this line:
> liq_equiv_sml at units = "mm" ; needs to be set to something other than ""
> above this line:
> contour = wrf_contour(a,wks,liq_equiv_sml,res1)
>
> I was able to get your plot to show the label bar title after appending
> that line. The reason for all this is that wrf_contour expects a units
> attribute to be set, and if it does not get one it internally
> sets lbTitleOn = False. (See line 2706 in WRFUserARW.ncl and trace up from
> there.) The current WRFUserARW.ncl coding precludes the user from manually
> setting the lbTitleString unless there is a units attribute that is set to
> something other than an empty string ("").
>
>
> To answer your question about creating a greater/less than or equal
> symbol: Strangely, I could not find that character in the NCL font tables.
> You could create them though by drawing a > or < and using function codes
> to back up and draw a _. For example:
> subtitle = "a >~H-16~_ 6"
>
> Hope that all helps. If you have any further questions let ncl-talk know.
> Adam
>
>
>
>
>
> On Sat, Apr 8, 2017 at 9:59 PM, Barry Lynn <barry.h.lynn at gmail.com> wrote:
>
>> Hi:
>>
>> I uploaded wrfout_d03*2017*03*
>>
>> and file_for_adam.nc
>>
>> The second file is needed because it contains all the processed data that
>> is supposed to be mapped.
>>
>> In the excerpted code (attached), the maps are the same size, but the
>> "ensemble mean" still does not appear. I am not sure why the maps are the
>> same size in this version of the code.
>>
>> One question; is it possible to write > with an underline?
>>
>> Thank you for the help!
>>
>> Barry
>>
>> On Sat, Apr 8, 2017 at 12:16 AM, Adam Phillips <asphilli at ucar.edu> wrote:
>>
>>> Hi Barry,
>>> My original email had a typo in it. The resource I wanted you to set was pmLabelBarOrthogonalPosF
>>> and not pmLaberlBarOrthogonalPosF.
>>>
>>> Regardless, if you would upload the wrf file you are using to our ftp
>>> site I will try to run your script from here. FTP directions:
>>> http://www.ncl.ucar.edu/report_bug.shtml#HowToFTP
>>>
>>> Let ncl-talk know when the file has been uploaded.
>>> Adam
>>>
>>>
>>>
>>>
>>>
>>>
>>> On Wed, Apr 5, 2017 at 9:05 PM, Barry Lynn <barry.h.lynn at gmail.com>
>>> wrote:
>>>
>>>> Hi:
>>>>
>>>> Making that substitution does not make a difference on the plot.
>>>> "Percent" does not appear.
>>>>
>>>>
>>>> contour = wrf_contour(a,wks,liq_equiv_sml,res2)
>>>>
>>>> has no effect.
>>>>
>>>> Also, adding that command to adjust the label bar gives a warning.
>>>>
>>>> warning:pmLaberlBarOrthogonalPosF is not a valid resource in
>>>> wrf_snow_panel_03_13_2017_4.0km-Alb_contour at this time
>>>>
>>>> On Wed, Apr 5, 2017 at 10:36 PM, Adam Phillips <asphilli at ucar.edu>
>>>> wrote:
>>>>
>>>>> Hi Barry,
>>>>> I think the panels are different size because (for whatever reason)
>>>>> the labelbar title is not being drawn on the first panel, and NCL uses the
>>>>> size needed for the 1st panel to allocate space for all other panels. (You
>>>>> can switch this. See example 24 here:
>>>>> http://www.ncl.ucar.edu/Applications/panel.shtml#ex24 )
>>>>>
>>>>> As to why the labelbar title does not show for plot #1: Looking at
>>>>> your script I don't see anything amiss. Try swapping res1 for res2 when you
>>>>> create your first plot and see if "percent" appears:
>>>>> line 401: contour = wrf_contour(a,wks,liq_equiv_sml,res2)
>>>>>
>>>>> You can also move the labelbar away from the plot by setting
>>>>> res1 at pmLaberlBarOrthogonalPosF to say -0.03.
>>>>>
>>>>> Try the above and let ncl-talk know the results if the changes do not
>>>>> yield the answer.
>>>>> Adam
>>>>>
>>>>> On Wed, Apr 5, 2017 at 7:11 AM, Barry Lynn <barry.h.lynn at gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Hi:
>>>>>>
>>>>>> The first plot (with res1 at lb...) will not plot the label above (or
>>>>>> anywhere) "ensemble mean."
>>>>>>
>>>>>> Also, the size of the first plot is larger than the others.
>>>>>>
>>>>>> I have attached the map, and the code.
>>>>>>
>>>>>> As far as I can tell, the definitions for res1 and res2 are the same,
>>>>>> but the results are different.
>>>>>>
>>>>>> Thank you for your help,
>>>>>>
>>>>>> Barry
>>>>>>
>>>>>> --
>>>>>> Barry H. Lynn, Ph.D
>>>>>> Senior Lecturer,
>>>>>> The Institute of the Earth Science,
>>>>>> The Hebrew University of Jerusalem,
>>>>>> Givat Ram, Jerusalem 91904, Israel
>>>>>> Tel: 972 547 231 170
>>>>>> Fax: (972)-25662581
>>>>>>
>>>>>> C.E.O, Weather It Is, LTD
>>>>>> Weather and Climate Focus
>>>>>> http://weather-it-is.com
>>>>>> Jerusalem, Israel
>>>>>> Local: 02 930 9525
>>>>>> Cell: 054 7 231 170
>>>>>> Int-IS: x972 2 930 9525
>>>>>> US 914 432 3108 <(914)%20432-3108>
>>>>>>
>>>>>> _______________________________________________
>>>>>> ncl-talk mailing list
>>>>>> ncl-talk at ucar.edu
>>>>>> List instructions, subscriber options, unsubscribe:
>>>>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Adam Phillips
>>>>> Associate Scientist, Climate and Global Dynamics Laboratory, NCAR
>>>>> www.cgd.ucar.edu/staff/asphilli/ 303-497-1726 <(303)%20497-1726>
>>>>>
>>>>> <http://www.cgd.ucar.edu/staff/asphilli>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Barry H. Lynn, Ph.D
>>>> Senior Lecturer,
>>>> The Institute of the Earth Science,
>>>> The Hebrew University of Jerusalem,
>>>> Givat Ram, Jerusalem 91904, Israel
>>>> Tel: 972 547 231 170
>>>> Fax: (972)-25662581
>>>>
>>>> C.E.O, Weather It Is, LTD
>>>> Weather and Climate Focus
>>>> http://weather-it-is.com
>>>> Jerusalem, Israel
>>>> Local: 02 930 9525
>>>> Cell: 054 7 231 170
>>>> Int-IS: x972 2 930 9525
>>>> US 914 432 3108 <(914)%20432-3108>
>>>>
>>>
>>>
>>>
>>> --
>>> Adam Phillips
>>> Associate Scientist, Climate and Global Dynamics Laboratory, NCAR
>>> www.cgd.ucar.edu/staff/asphilli/ 303-497-1726 <(303)%20497-1726>
>>>
>>> <http://www.cgd.ucar.edu/staff/asphilli>
>>>
>>
>>
>>
>> --
>> Barry H. Lynn, Ph.D
>> Senior Lecturer,
>> The Institute of the Earth Science,
>> The Hebrew University of Jerusalem,
>> Givat Ram, Jerusalem 91904, Israel
>> Tel: 972 547 231 170
>> Fax: (972)-25662581
>>
>> C.E.O, Weather It Is, LTD
>> Weather and Climate Focus
>> http://weather-it-is.com
>> Jerusalem, Israel
>> Local: 02 930 9525
>> Cell: 054 7 231 170
>> Int-IS: x972 2 930 9525
>> US 914 432 3108 <(914)%20432-3108>
>>
>
>
>
> --
> Adam Phillips
> Associate Scientist, Climate and Global Dynamics Laboratory, NCAR
> www.cgd.ucar.edu/staff/asphilli/ 303-497-1726 <(303)%20497-1726>
>
> <http://www.cgd.ucar.edu/staff/asphilli>
>
--
Barry H. Lynn, Ph.D
Senior Lecturer,
The Institute of the Earth Science,
The Hebrew University of Jerusalem,
Givat Ram, Jerusalem 91904, Israel
Tel: 972 547 231 170
Fax: (972)-25662581
C.E.O, Weather It Is, LTD
Weather and Climate Focus
http://weather-it-is.com
Jerusalem, Israel
Local: 02 930 9525
Cell: 054 7 231 170
Int-IS: x972 2 930 9525
US 914 432 3108
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170419/41af4fed/attachment-0001.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: wrf_snow_panel_03_13_2017_4.0km-NYC.png
Type: image/png
Size: 1417550 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170419/41af4fed/attachment-0001.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dumb5.ncl
Type: application/octet-stream
Size: 15284 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170419/41af4fed/attachment-0001.obj
More information about the ncl-talk
mailing list