[gradsusr] GrADS: Use of %

Jeff Duda jeffduda319 at gmail.com
Tue Nov 19 13:58:07 EST 2013


The % sign is used for concatenation of strings.  However, the
concatenation is implied by the use of repeated single quotes with a space
between, which implies that if that command were issued at the command
prompt, the space would already be in there.  Thus the command would be
okay.  The example shows how the % doesn't NEED to be used, but how it CAN
be used.

Jeff Duda


On Tue, Nov 19, 2013 at 12:50 PM, Mayes, Fred <Fred.Mayes at eia.gov> wrote:

> The script URL provides the following example:
>
> 'open my_sst_dataset.ctl'
> prompt 'Enter min and max latitudes: '
> pull minlat maxlat
> prompt 'Enter min and max longitudes: '
> pull minlon maxlon
> 'set lat 'minlat%' '%maxlat
> 'set lon 'minlon' 'maxlon
> 'display sst'
>
> Why is the "%" sign not used with the "set lon" command?
>
> Fred M.
>
> -----Original Message-----
> From: gradsusr-bounces at gradsusr.org [mailto:gradsusr-bounces at gradsusr.org]
> On Behalf Of gradsusr-request at gradsusr.org
> Sent: Tuesday, November 19, 2013 12:00 PM
> To: gradsusr at gradsusr.org
> Subject: gradsusr Digest, Vol 45, Issue 41
>
> 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. Re: Eurocentric global map (Cara Duckworth)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Tue, 19 Nov 2013 17:00:20 +0000
> From: Cara Duckworth <cara.duckworth at keble.ox.ac.uk>
> Subject: Re: [gradsusr] Eurocentric global map
> To: GrADS Users Forum <gradsusr at gradsusr.org>
> Message-ID:
>         <A4E83836710D234FA6C4B8ECB9E60B1F3051C9 at MBX09.ad.oak.ox.ac.uk>
> Content-Type: text/plain; charset="us-ascii"
>
> Hi Jim
>
> Thanks for your response. If I set lon to 180,540 the problem flips.
>
> If set lon to 0 540, no values are attached to 360+. Is there a way of
> sorting this?
>
> Best,
> Cara
>
> [cid:F62102ED-71DA-43A7-94A9-981A4C0488B5]
>
> On 19 Nov 2013, at 16:22, "James T. Potemra" <jimp at hawaii.edu<mailto:
> jimp at hawaii.edu>>
>  wrote:
>
> Cara:
>
> Can you try 'set lon 180 540'?  This should work if your longitude values
> are continuous.
>
> Jim
> On 11/19/13 5:44 AM, Cara Duckworth wrote:
> Hi Chuck,
>
> Thanks for your response. Yes, I just checked: lon = 0,360.
>
> Is there a way that I can change this so that I can plot the global map
> from lon -180 to 180 (with Europe in the middle)?
> When I plot it at lon=0,360, the map is fine but America is in the centre
> and I need Europe in the centre.
>
> Best,
> Cara
>
> On 19 Nov 2013, at 15:15, Charles Seman - NOAA Federal <
> charles.seman at noaa.gov<mailto:charles.seman at noaa.gov>> wrote:
>
> Cara,
>
> Check to see if the variable you're trying to plot has been defined
> locally in GrADS and what the longitude range is for it.  I was able to
> replicate the issue by defining a local GrADS variable for lon = (0,360)
> and then when displaying it for lon = (-180,180) the left half was missing.
>
> Hope this helps,
> Chuck
>
> On 11/19/2013 09:33 AM, Cara Duckworth wrote:
> Thanks Alan and Chris,
>
> I'm still having troubles plotting the map.
> When I use "set lon -180 180", one half of the plot is missing (see image
> attached)
>
> Without this instruction the map is fine (with all data displayed), though
> Europe is not in the centre.
> Any ideas as to what I have done wrong?
>
> Best,
> Cara
>
>
>
>
>
> On 19 Nov 2013, at 13:25, Bill Reilly <bill_reilly at compuserve.com<mailto:
> bill_reilly at compuserve.com>
> <mailto:bill_reilly at compuserve.com>> wrote:
>
> Alan:
>
> I think you mean:
>
> set lon -180 180
>
> --
>
> Bill Reilly
> www.passageweather.com<http://www.passageweather.com> <
> http://www.passageweather.com>
>
> On 11/19/2013 1:30 PM, Alan Robock wrote:
> Dear Cara
>
> set lat -180 180
>
> or if you don't want to split Alaska:
>
> set lat -170 190
> Alan Robock
>
> Alan Robock, Distinguished Professor
>  Editor, Reviews of Geophysics
>  Director, Meteorology Undergraduate Program
> Department of Environmental Sciences             Phone: +1-848-932-5751
> Rutgers University                                 Fax: +1-732-932-8644
> 14 College Farm Road                  E-mail:robock at envsci.rutgers.edu<
> http://envsci.rutgers.edu>
> New Brunswick, NJ 08901-8551  USAhttp://envsci.rutgers.edu/~robock
>                                          http://twitter.com/AlanRobockWatch my 18 min TEDx talk athttp://
> www.youtube.com/watch?v=qsrEk1oZ-54
>
> On 11/19/2013 6:54 AM, Cara Duckworth wrote:
> Dear users,
>
> I need to plot a global map, which is centred on the Prime Meridian (i.e.
> a Eurocentric map).
> Currently, the Prime Meridian is at either edge of my plot. How do I
> change this?
>
> Thanks,
> Cara
>
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
> --
>
> Please note that Charles.Seman at noaa.gov<mailto:Charles.Seman at noaa.gov>
> should be considered my NOAA email address, not cjs at gfdl.noaa.gov<mailto:
> cjs at gfdl.noaa.gov>.
>
> ********************************************************************
>  Charles Seman                                Charles.Seman at noaa.gov
> <mailto:Charles.Seman at noaa.gov>
>  U.S. Department of Commerce / NOAA / OAR
>  Geophysical Fluid Dynamics Laboratory         voice: (609) 452-6547
>  201 Forrestal Road                              fax: (609) 987-5063
>  Princeton, NJ  08540-6649            http://www.gfdl.noaa.gov/~cjs/
> ********************************************************************
>
> "The contents of this message are mine personally and do not reflect any
> official or unofficial position of the United States Federal Government,
> the United States Department of Commerce, or NOAA."
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
> http://gradsusr.org/mailman/listinfo/gradsusr
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://gradsusr.org/pipermail/gradsusr/attachments/20131119/049cab99/attachment.html
> -------------- next part --------------
> A non-text attachment was scrubbed...
> Name: Screen Shot 2013-11-19 at 16.57.54.png
> Type: image/png
> Size: 338604 bytes
> Desc: Screen Shot 2013-11-19 at 16.57.54.png Url :
> http://gradsusr.org/pipermail/gradsusr/attachments/20131119/049cab99/attachment.png
>
> ------------------------------
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>
> End of gradsusr Digest, Vol 45, Issue 41
> ****************************************
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>



-- 
Jeff Duda
Graduate research assistant
University of Oklahoma School of Meteorology
Center for Analysis and Prediction of Storms
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20131119/73aea165/attachment-0001.html 


More information about the gradsusr mailing list