Re: how to deliver an environment variable into ncl script

From: Carl Schreck <cjschrec_at_nyahnyahspammersnyahnyah>
Date: Wed Jun 18 2014 - 08:59:44 MDT

I usually use
ncl script.ncl var=\"$var\"

    Carl


On Wed, Jun 18, 2014 at 10:22 AM, Karin Meier-Fleischer <
meier-fleischer@dkrz.de> wrote:

> Hi Feng,
>
> try ncl 'var="'$var'"' script.ncl
>
> Bye,
> Karin
>
>
> Am 18.06.2014 um 16:06 schrieb ChenFeng <fengfengabc003@163.com>:
>
> > Hi all,
> >
> > I need to deliver an environment variable into ncl script. Such as:
> > export var="0300"
> > ncl var="$var" script.ncl
> > But I found the kind of variable var change from string to integer (in
> the ncl script the var is 300, rather than "0300").
> > If I use
> > ncl 'var="$var"' script.ncl
> > then the variable in script is "$var", also not "0300".
> > I have no idea about it.
> > It is very appreciate if anybody can solve the problem.
> >
> > feng
> > _______________________________________________
> > 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
>



--

 <http://www.cicsnc.org/>
 <http://www.researcherid.com/rid/B-8711-2011>[image:
http://www.researcherid.com/rid/B-8711-2011]
<http://www.researcherid.com/rid/B-8711-2011>
*Carl J. Schreck III, PhD*
*Research Associate*
Cooperative Institute for Climate and Satellites NC <http://cicsnc.org/>
North Carolina State University <http://ncsu.edu/>
NOAA's National Climatic Data Center <http://ncdc.noaa.gov/>
151 Patton Ave, Asheville, NC 28801
e: cjschrec@ncsu.edu
o: +1 828 257 3140
CycloneCenter.org: Help analyze tropical cyclones
<http://cyclonecenter.org/>
monitor.cicsnc.org/mjo: See recent MJO diagnostics
<http://monitor.cicsnc.org/mjo/>

Received on Wed Jun 18 03:00:39 2014

This archive was generated by hypermail 2.1.8 : Wed Jul 23 2014 - 15:33:46 MDT