[gradsusr] (no subject)

Thomas Davies tsd.davies at gmail.com
Tue Mar 22 07:11:13 EDT 2016


You need to 'set dfile 2' after opening the second file and then define the
variable. Or define it as temp.2 to reference the second file

On Tue, 22 Mar 2016 09:38 Gargi Akhoury, <gargiakhoury at bitmesra.ac.in>
wrote:

> Dear Grads Users,
>          It's a very simple problem but I am facing problem to solve this.
> I have two netcdf files like:
> temp.nc
> mslp.nc
>
> I want to open these two files together and display the image. I have done
> it like this.
>
> 'sdfopen mslp.nc'
> 'sdfopen t1000.nc'
> 'define mslp=ave(pressure,t=1,t=420,12)'
> 'd mslp'
> 'c'
> 'define tmp=ave(temp-273.15,t=1,t=420,12)'
> 'd tmp'
>
> But I am getting error in this. The error is:
>
> "define tmp=ave(temp-273.15,t=1,t=420,12)
> Averaging.  dim = 3, start = 1, end = 420
> Syntax Error:  Invalid Operand
>   'temp' not a variable or function name
> Operation Error:  Error from ave function
>   Error ocurred at column 1
> DEFINE error:  Invalid expression."
>
> Kindly, help me regarding this.
>
> Kind Regards
> Gargi
>
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20160322/00352308/attachment-0001.html 


More information about the gradsusr mailing list