[Thread Prev][Thread Next][Index]

Re: [ferret_users] Re: whether any provision is available to use shell commands, with ferret



Akshay,
I generally prefer making symbols for this kind of thing, as they give a bit more flexibility. So I would tend to do it like this:

  define symbol vname = `variable`
  LET/units="($vname)[d=2],RETURN=units`"/TITLE="`anomaly_title`" `anomaly_var` = `variable`_anomaly


Or, another solution is the SET ATTRIBUTE command. To have the new variable to inherit all the attributes of the old variable:

   let `anomaly_var` = `variable`_anomaly
   set att/like=`variable`[d=2]  `anomaly_var`

Ansley


On 3/4/2013 9:15 PM, Akshay Hegde wrote:
do you have any idea about this

LET/units="``variable`[d=2],RETURN=units`"/TITLE="`anomaly_title`"
`anomaly_var` = `variable`_anomaly

unable to get units here,,, grave accents..problem


please help..


Thanks in advance,,

Akshay

On Mon, Jan 7, 2013 at 12:57 PM, Akshay Hegde <akshay.k.hegde@xxxxxxxxx> wrote:
Whether its possible to use shell commands in ferret...something like
this...
because modifying many files kills time, if its possible something like this
using for loop, it will be helpful..


sp for file in *.nc; do ! not working...

use $file

!do some operation say

let/units="meter"/title="my title" myvariable1 = xyz_new1

let/units="cm"/title="my title" myvariable2 = xyz_new2

list/file=$file_modifile.nc/format=cdf/clobber xyz_new1, xyz_new2
done


Awaiting for reply...



- Akshay



[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce / NOAA / OAR / PMEL / Ferret

Privacy Policy | Disclaimer | Accessibility Statement