Re: draw wrf domain in ncl

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue Apr 15 2014 - 08:50:44 MDT

Hi,

The UNIX ¡°cut¡± commands were added to some NCL scripts before we had the ¡°str_xxx¡± functions, which allow you to parse strings.

If you need to parse strings, using ¡°=¡° as a separator, please see ¡°str_get_field¡±:

http://www.ncl.ucar.edu/Document/Functions/Built-in/str_get_field.shtml

For example, if you have the string, ¡°pole_lat = 90.0¡± and you need to get the ¡°90.0¡± value as a float:

   str = "pole_lat = 90.0"
   pole_lat = tofloat(str_get_field(str,2,¡±=¡°))

¡ªMary

On Apr 15, 2014, at 7:28 AM, Yuqiang Zhansg <yuqiangzhang.thu@gmail.com> wrote:

> ¡°Cut¡± is a UNIX command. It means to separate the string with ¡°=¡± first and then get the second one (f2). You can refer to the Wikipedia for help.
> http://en.wikipedia.org/wiki/Cut_(Unix)
>
>
> Regards,
> Yuqiang
>
> From: ncl-talk-bounces@ucar.edu [mailto:ncl-talk-bounces@ucar.edu] On Behalf Of »ÆСÏɶù
> Sent: Tuesday, April 15, 2014 7:03 AM
> To: ncl-talk
> Subject: draw wrf domain in ncl
>
> hi all:
> I found the plotgrids.ncl in ARW OnlineTutorial,but I do not know how edit it for my own purpose.
> and " | cut -f2 -d'=' | cut -f"+n+" -d','" what is that mean?
> _______________________________________________
> 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 Tue Apr 15 08:50:54 2014

This archive was generated by hypermail 2.1.8 : Tue Apr 15 2014 - 10:45:19 MDT