[Thread Prev][Thread Next][Index]

Re: [ferret_users] how to do embedded expression inside an embedded expression with grave accent



Hi,


On Wed, Oct 10, 2018 at 9:05 PM Xiaoyu Bai <xbai1@xxxxxxxx> wrote:
Hi Ghetiya,

Yes, I wan to read all the files in through the repeat loop. When you say nested loop, do you mean let datset=0; repeat/range=1:8 (let datset=`datset+1`; use `files_CNRM[X=datset]`)? It didn't work.

^ Yes, you are correct, I also encountered similar problem, it seems ferret is not taking nested definition of variable.
The error message is like **ERROR: command syntax: DATSET // SET DAT/FORM=CDF `files_CNRM[X=datset]`. I feel datset needs a pair of grave accent to make it as an variable. However, ferret considers the nearest two grave accents as a pair. 
I might need to read my files in one by one instead of using repeat loop.

^ But once I used syntax like this which worked: repeat/range=1:7/name=aa (use file_name_`aa`.nc;) 
Anyway if not, then yes for now, you may have to use one by one.
Thank you very much and have a nice day. 

Welcome. 

--
G Satyesh



--
Xiaoyu


--
G Satyesh


[Thread Prev][Thread Next][Index]