[ncl-talk] change the Y AxisString according to the example 'vector_5.ncl'

Mary Haley haley at ucar.edu
Wed May 3 09:48:25 MDT 2017


Hi Grace,

There's currently no resource for this, but one could easily modify the
"gsn_csm_pres_hgt" function in
$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl and make the change
themselves.

It's a quick change, so I did this for you. I added a new resource
called  gsnPresHgtHeightLabel, because we already have a
gsnPresHgtHeightLabelOn resource:

I created a new ticket for this (NCL-2603 for your reference). I will try
to get this into NCL V6.4.1 or 6.5.0.
Attached is a modified version of "gsn_csm_pres_hgt" and an example that
uses this new resource.

You need to add the following load statement at the top of your script,
after any other load statements you might have:

load "./gsn_csm_pres_hgt_mod.ncl"

 res at gsnPresHgtHeightLabel = "My own height label"

As a side, we also have a ticket to allow users to add both a left and
right Y axis label, so you are not just limited to the one "tiYAxisString".
This ticket is NCL-136, which shows you how old the request is!

--Mary




On Sat, Apr 29, 2017 at 9:34 PM, grace <313695096 at qq.com> wrote:

> Hi:
>       All,I have write a script according to the example
> 'vector_5.ncl'(gsn_csm_pres_hgt_vector).
>       I am wondering how to change the Y AxisString,because the default
> title and unit pattern is 'pressure(mb)'&'height(km)'.But I want to
> change it to 'pressure/mb'&'height/km',I am try to set 'res at tiYAxisString
>   = "Pressure/mb"',but it can only change one of them ,I can not find any
> information in the example script.
>  How can I slove the problem?
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170503/b24d96b1/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D3884BC9 at AFF89158.5F5B0559.jpg
Type: image/jpeg
Size: 106547 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170503/b24d96b1/attachment.jpg 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pres_hgt_example.ncl
Type: application/octet-stream
Size: 1348 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170503/b24d96b1/attachment.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gsn_csm_pres_hgt_mod.ncl
Type: application/octet-stream
Size: 9380 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170503/b24d96b1/attachment-0001.obj 


More information about the ncl-talk mailing list