[gradsusr] If function and Shading color

T. haghroosta haghroosta at hotmail.com
Tue Dec 17 09:14:27 EST 2013


Dear Dr. Sujata Mandke,
 
Thank you for your guidance.
 
Regards,
 
Tahereh

 
> From: gradsusr-request at gradsusr.org
> Subject: gradsusr Digest, Vol 46, Issue 30
> To: gradsusr at gradsusr.org
> Date: Tue, 17 Dec 2013 08:44:43 -0500
> 
> Send gradsusr mailing list submissions to
> 	gradsusr at gradsusr.org
> 
> To subscribe or unsubscribe via the World Wide Web, visit
> 	http://gradsusr.org/mailman/listinfo/gradsusr
> or, via email, send a message with subject or body 'help' to
> 	gradsusr-request at gradsusr.org
> 
> You can reach the person managing the list at
> 	gradsusr-owner at gradsusr.org
> 
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of gradsusr digest..."
> 
> 
> Today's Topics:
> 
>    1. If function (T. haghroosta)
>    2. Shading color (T. haghroosta)
>    3. Re: Shading color (Sujata Mandke)
>    4. Re: If function (Sujata Mandke)
>    5. Cannot contour grid - all undefined values - GRADS
>       (Anil Kumar Sharma)
>    6. EOF by Grads (Chinh ta huu)
>    7. unable to plot 2 files together (Geeta Geeta)
>    8. Re: Cannot contour grid - all undefined values - GRADS
>       (Jennifer Adams)
> 
> 
> ----------------------------------------------------------------------
> 
> Message: 1
> Date: Tue, 17 Dec 2013 05:42:18 +0000
> From: "T. haghroosta" <haghroosta at hotmail.com>
> Subject: [gradsusr] If function
> To: "gradsusr at gradsusr.org" <gradsusr at gradsusr.org>
> Message-ID: <DUB121-W2150B61ABD17604C8A0A96DDDB0 at phx.gbl>
> Content-Type: text/plain; charset="windows-1256"
> 
> Hi All,
>  
> Can I use "if function" in grads? How? Lead me please.
>  
> Regards,
>  
> T.
>  		 	   		  
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/8c90017e/attachment-0001.html 
> 
> ------------------------------
> 
> Message: 2
> Date: Tue, 17 Dec 2013 06:49:43 +0000
> From: "T. haghroosta" <haghroosta at hotmail.com>
> Subject: [gradsusr] Shading color
> To: "gradsusr at gradsusr.org" <gradsusr at gradsusr.org>
> Message-ID: <DUB121-W21D9FAE3B0C845F96B03BADDDB0 at phx.gbl>
> Content-Type: text/plain; charset="windows-1256"
> 
> Hi All,
>  
> How can I change the color of shading for command 'set gxout shaded'? 
>  
> Regards,
>  
> T.
>  		 	   		  
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/c743bc6d/attachment-0001.html 
> 
> ------------------------------
> 
> Message: 3
> Date: Tue, 17 Dec 2013 14:22:00 +0530 (IST)
> From: Sujata Mandke <amin at tropmet.res.in>
> Subject: Re: [gradsusr] Shading color
> To: GrADS Users Forum <gradsusr at gradsusr.org>
> Message-ID:
> 	<62831487.5131.1387270320751.JavaMail.root at cluster1.tropmet.res.in>
> Content-Type: text/plain; charset="utf-8"
> 
> Hi!
>   You can use following command
> set ccols col1 col2 col3 ... colN
> 
> Sets specific color numbers for contour levels specified by set clevs
> For details please refer Grads documentation(section on Graphics Options)
> http://www.iges.org/grads/gadoc/ 
> Regards
> Dr. Sujata Mandke
> IITM,pune-8
> 
> 
> ----- Original Message -----
> From: T. haghroosta <haghroosta at hotmail.com>
> To: gradsusr at gradsusr.org
> Sent: Tue, 17 Dec 2013 12:19:43 +0530 (IST)
> Subject: [gradsusr] Shading color
> 
> Hi All,
>  
> How can I change the color of shading for command 'set gxout shaded'? 
>  
> Regards,
>  
> T.
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/d3391c83/attachment-0001.html 
> 
> ------------------------------
> 
> Message: 4
> Date: Tue, 17 Dec 2013 14:29:58 +0530 (IST)
> From: Sujata Mandke <amin at tropmet.res.in>
> Subject: Re: [gradsusr] If function
> To: GrADS Users Forum <gradsusr at gradsusr.org>
> Message-ID:
> 	<1057765933.5178.1387270798164.JavaMail.root at cluster1.tropmet.res.in>
> Content-Type: text/plain; charset="utf-8"
> 
> Hi!
>   Yes.  You can use if function in grads as follows
> -------------------------------------------------------------
> 
> if expression
> script record
> endif
> ---------------
> The script records following if
> expression are executed if the
> expression evaluates to a string
> containing the character 1.
> If the expression evaluates to 0, then the
> script records in the if block
> are not executed and the
> script continues with record following endif.
> 
> More details are available in Grads documentation on following link
> http://www.iges.org/grads/gadoc/
> (Refer section on Grads scripting language)
> Regards
> Sujata Mandke
> 
> 
> 
> ----- Original Message -----
> From: T. haghroosta <haghroosta at hotmail.com>
> To: gradsusr at gradsusr.org
> Sent: Tue, 17 Dec 2013 11:12:18 +0530 (IST)
> Subject: [gradsusr] If function
> 
> Hi All,
>  
> Can I use "if function" in grads? How? Lead me please.
>  
> Regards,
>  
> T.
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/76a17955/attachment-0001.html 
> 
> ------------------------------
> 
> Message: 5
> Date: Tue, 17 Dec 2013 16:20:33 +0530
> From: Anil Kumar Sharma <aanil649 at gmail.com>
> Subject: [gradsusr] Cannot contour grid - all undefined values - GRADS
> To: gradsusr at gradsusr.org
> Message-ID:
> 	<CAA=EjHu9j_HnXWGY2pLe2EqywZajTeG1cp-CYdBkfYg+125MTA at mail.gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
> 
> *Hi All,*
> *This might be silly problem, but I am Stuck.*
> *I have NetCDF file downloaded from NCEP
> <http://nomads.ncep.noaa.gov/pub/data/nccf/com/rtofs/prod/rtofs.20131216/>containing
> ocean current components. When I opened NetCDF using SDFOpen command in
> Grads*
> 
> *ga-> sdfopen C:\t1\20131212_rtofs_glo_2ds_n024_daily_prog.nc
> <http://20131212_rtofs_glo_2ds_n024_daily_prog.nc>*
> 
> *It gave the text on screen*
> 
> Scanning self-describing file:  C:\t1\
> 20131212_rtofs_glo_2ds_n024_daily_prog.nc
> SDF file C:\t1\20131212_rtofs_glo_2ds_n024_daily_prog.nc is open as file 1
> LON set to 1 4500
> LAT set to 1 3298
> LEV set to 1 1
> Time values set: 2013:12:10:0 2013:12:10:0
> E set to 1 1
> 
> *I can see LON value upto 4500, and LAT value upto 3298. *
> 
> *I want to plot current variables for*
> *          longitude  -179 - 179 degree*
> *          latitude -89 to 89 degree*
> 
> So what I need to change or How can I get this working??
> when I set these values using SET command
> ga-> set lon -179 179
> LON set to -179 179
> ga-> set lat -89 89
> LAT set to -89 89
> ga-> d skip(u_velocity,5,5);skip(v_velocity,5,5)
> its gives me error
> 
> *Cannot contour grid - all undefined values.*
> 
> 
> *Please lead me.*
> 
> *Thanks in Advance !!!*
> 
> *B/Regards,*
> *Anil Kumar*
> *Pune, India*
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/35af8e2a/attachment-0001.html 
> 
> ------------------------------
> 
> Message: 6
> Date: Tue, 17 Dec 2013 06:16:37 -0500
> From: Chinh ta huu <chinhth2010 at gmail.com>
> Subject: [gradsusr] EOF by Grads
> To: GrADS Users Forum <gradsusr at gradsusr.org>
> Message-ID:
> 	<CAHiZ=QM8NP8R7jkXuMdLTEFJYm87Ju1ewq+7841+UCwgFAXJQA at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
> 
> Dear all users
> 
> I am going to use Grads to implement EOF analysis. But in installed
> process I have a problem as bellow:
> 
> If you never used a  User Defined Function (UDF), set your environment
> variable GAUDFT to point to your  UDF table file, for example:
>   csh:
>  $ setenv GAUDFT $HOME/grads/udft.txt
>  sh:
>  $ export GAUDFT=$HOME/grads/udft.txt
> 
> I don't understand about UDF as well as GAUDFT and process to point
> out UDF table. Anyone give me comments
> Thank you very much
> 
> -- 
> (Mr.) Ta Huu Chinh
> National, Weather Forecasting Center, Ha Noi, Viet Nam.
> No: 4th, Dang Thai Than, Hoan Kiem, Ha Noi
> Tel: 84-903-298-856
> Office: 84-43-824-4917
> Email: chinhth2010 at gmail.com
> Website: http://vn.myblog.yahoo.com/chinhth2005/
> Website: http://bestknowledge-chinhth.blogspot.com/
> Website: http://anhcuoidep.vn
> 
> 
> ------------------------------
> 
> Message: 7
> Date: Tue, 17 Dec 2013 17:32:00 +0530
> From: Geeta Geeta <geeta124 at hotmail.com>
> Subject: [gradsusr] unable to plot 2 files together
> To: grads grads <gradsusr at gradsusr.org>
> Message-ID: <BLU178-W8C11FB42BD943FFC3AB228ADB0 at phx.gbl>
> Content-Type: text/plain; charset="iso-8859-1"
> 
> 
> Hi 
> I have to open a no of files in grads which are 
> /store_file/03june2011/wrf-outp_d01_2011060303.ctl'
> /store_file/06june2011/wrf-outp_d01_2011060603.ctl'
> /store_file/07june2011/wrf-outp_d01_2011060703.ctl'
>  
> ............ so on. 
> 
>  
> ga-> open /expr/store_file/03june2011/wrf-outp_d01_2011060303.ctl
> Scanning description file:  /expr/store_file/03june2011/wrf-outp_d01_2011060303.ctlData file /expr/store_file/03june2011/wrf-outp_d01_2011060303.dat is open as file 1LON set to 73.9429 87.0571
> LAT set to 9.09704 21.7107
> LEV set to 1000 1000
> Time values set: 2011:6:3:3 2011:6:3:3
> ga-> open /expr/store_file/06june2011/wrf-outp_d01_2011060603.ctl
> Scanning description file:  /expr/store_file/06june2011/wrf-outp_d01_2011060603.ctlData file /expr/store_file/06june2011/wrf-outp_d01_2011060603.dat is open as file 2ga-> d rainc.1+rainnc.1+rainc.2+rainnc.2
> Data Request Warning:  Request beyond file limits
>   Entire grid contents are set to missing data
>   Dimension ranges are:  X = 1 163  Y = 1 163  Z = 1 1  T = -71 1
>   Warning issued for variable = rainc.2
> Data Request Warning:  Request beyond file limits
>   Entire grid contents are set to missing data
>   Dimension ranges are:  X = 1 163  Y = 1 163  Z = 1 1  T = -71 1
>   Warning issued for variable = rainnc.2
> Cannot contour grid - all undefined values
> ga->
> 
>  
> But Grads is NOT plotting the data???????
>  
> Kindly advice
> geeta
>  		 	   		  
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/e1f96164/attachment-0001.html 
> 
> ------------------------------
> 
> Message: 8
> Date: Tue, 17 Dec 2013 08:44:44 -0500
> From: Jennifer Adams <jma at cola.iges.org>
> Subject: Re: [gradsusr] Cannot contour grid - all undefined values -
> 	GRADS
> To: GrADS Users Forum <gradsusr at gradsusr.org>
> Message-ID: <927B4BB0-32AE-4733-B2D2-21E2AFCB141F at cola.iges.org>
> Content-Type: text/plain; charset="iso-8859-1"
> 
> Hi, Anil -- 
> This is not a silly problem. The sdfopen command opens this file because it has coordinates that have an attribute named "axis" with values of "X", "Y", and "T". This is enough information for GrADS to decide to map those to LON, LAT, and TIME. Unfortunately, the actual grid latitude and longtidue values are 2-dimensional data values, and so the mapping returned by sdfopen is for the abstract grid, not the real lat/lon grid. Here is the relevant info from the ncdump output:
> 
>        float Latitude(Y, X) ;
>                 Latitude:standard_name = "latitude" ;
>                 Latitude:units = "degrees_north" ;
>         float Longitude(Y, X) ;
>                 Longitude:standard_name = "longitude" ;
>                 Longitude:units = "degrees_east" ;
> 
> This is a curvilinear grid, so GrADS will not handle it properly without some intervention. Go ahead and 'display latitude' after opening the file with sdfopen and you will see how the contours bend at high northern latitudes. If you are not interested in data that is northward of ~45N (the approximate latitude where the grid starts to curve), then you could truncate the grid and only look at the gridpoints where the grid values are rectilinear. Otherwise, you will need a PDEF file to interpolate. I have used ESMF's RegridWeightGen tool to do this for CMIP5 data that are on curvilinear grids. Details about that workflow are in ftp://cola.gmu.edu/pub/jma/cmip5. Depending on how ambitious you are, you can try to adapt these scripts to this data set. 
> 
> --Jennifer
> 
> 
> 
> On Dec 17, 2013, at 5:50 AM, Anil Kumar Sharma wrote:
> 
> > Hi All,
> > This might be silly problem, but I am Stuck.
> > I have NetCDF file downloaded from NCEP containing ocean current components. When I opened NetCDF using SDFOpen command in Grads
> > 
> > ga-> sdfopen C:\t1\20131212_rtofs_glo_2ds_n024_daily_prog.nc
> > 
> > It gave the text on screen
> > 
> > Scanning self-describing file:  C:\t1\20131212_rtofs_glo_2ds_n024_daily_prog.nc
> > SDF file C:\t1\20131212_rtofs_glo_2ds_n024_daily_prog.nc is open as file 1
> > LON set to 1 4500
> > LAT set to 1 3298
> > LEV set to 1 1
> > Time values set: 2013:12:10:0 2013:12:10:0
> > E set to 1 1
> > 
> > I can see LON value upto 4500, and LAT value upto 3298. 
> > 
> > I want to plot current variables for
> >           longitude  -179 - 179 degree
> >           latitude -89 to 89 degree
> > 
> > So what I need to change or How can I get this working??
> > when I set these values using SET command 
> > ga-> set lon -179 179
> > LON set to -179 179
> > ga-> set lat -89 89
> > LAT set to -89 89
> > ga-> d skip(u_velocity,5,5);skip(v_velocity,5,5)
> > its gives me error 
> > Cannot contour grid - all undefined values.
> > 
> > 
> > Please lead me.
> > 
> > Thanks in Advance !!!
> > 
> > B/Regards,
> > Anil Kumar
> > Pune, India
> > _______________________________________________
> > gradsusr mailing list
> > gradsusr at gradsusr.org
> > http://gradsusr.org/mailman/listinfo/gradsusr
> 
> --
> Jennifer M. Adams
> Center for Ocean-Land-Atmosphere Studies (COLA)
> 111 Research Hall, Mail Stop 2B3
> George Mason University
> 4400 University Drive
> Fairfax, VA 22030 
> 
> 
> 
> 
> 
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/d0b2a61d/attachment.html 
> 
> ------------------------------
> 
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
> 
> 
> End of gradsusr Digest, Vol 46, Issue 30
> ****************************************
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131217/d6cd5336/attachment-0001.html 


More information about the gradsusr mailing list