<html><body><div style="color:#000; background-color:#fff, font-family:garamond, new york, times, serif;font-size:14pt">Dear Ramaphane, <br>As Muhammad has indicated, the script runs. BUT your Objective is to plot the station Locations on the map, with station names. If that is the <br>case, you need to open&nbsp; a file (eg. open model.ctl) to set the environment (<span style="font-weight: bold;">so that you don't get the error massage of No scaling environment)</span> and display a variable. The trick I normally use so that I get a blank map is to set cmin a value higher than the maximum value of the variable (<span style="font-weight: bold;">there could be a better way of doing this, I hope somebody will point it out</span>). For example I set cmin 10 before diplaying pr variable in model.ctl.<br>You also need to zoom in your domain using set lat and set lon. <br>See attached map(city.png) I have done with the script.<br>&nbsp;Hope this will help.<br
 class="yui-cursor"><span></span><div>&nbsp;</div><div id="RTEContent"><div><div><b><em>===================================================</em></b></div><div><b><em><font color="#007f40" face="lucida console, sans-serif">ZABLONE OWITI<br></font><font face="garamond, new york, times, serif">GRADUATE STUDENT<br>Nanjing University of Information, Science and Technology<br>College of International Education<br>Add: 219 Ning Liu Rd, Nanjing, Jiangsu, 21004, P.R. China<br></font></em></b><font color="#333333" face="garamond, new york, times, serif">Tel: +86-25-58731402<br>Fax: +86-25-58731456</font></div><div><b><em><font face="garamond, new york, times, serif">Mob. 15077895632</font></em></b></div><div><b><em>Website: <a rel="nofollow" target="_blank" href="http://www.nuist.edu.cn/">www.nuist.edu.cn</a><br></em></b><i><strong>====================================================<br></strong><span class="yui_3_2_0_2_129722199861452" style="font-style: italic;
 font-family: inherit;"><div class="MsoNormal"><i><span style="color: rgb(227, 108, 10); font-size: 12pt;">"The real art of conversation is not only to say the right thing at the right time, but also to leave unsaid the wrong thing at the tempting moment."</span></i><i><span style="color: rgb(227, 108, 10); font-size: 12pt;"></span></i></div><div class="MsoNormal">&nbsp;</div></span></i><br></div></div></div><div style="font-family: inherit; font-size: 14pt;"><br><div style="font-family: inherit; font-size: 12pt;"><font face="Arial" size="2"><div style="border: 1px solid rgb(204, 204, 204); line-height: 0pt; font-size: 0pt; margin: 5px 0px; padding: 0pt;" readonly="true" class="hr" contenteditable="false"></div><b><span style="font-weight: bold;">From:</span></b> Muhammad Rahiz &lt;muhammad.rahiz@ouce.ox.ac.uk&gt;<br><b><span style="font-weight: bold;">To:</span></b> GrADS Users Forum &lt;gradsusr@gradsusr.org&gt;<br><b><span style="font-weight:
 bold;">Cc:</span></b> <br><b><span style="font-weight: bold;">Sent:</span></b> Tuesday, 8 February 2011 11:23 PM<br><b><span style="font-weight: bold;">Subject:</span></b> Re: [gradsusr] [BULK]  Re:  opening text file data<br></font><br> I am able to run the script. See results below<br><br>lat is -18.38 lon is 21.85 and the city is Shakawe<br>start is 1<br>lat is -17.82 lon is 25.15 and the city is Kasane<br>start is 2<br>lat is -19.98 lon is 23.42 and the city is Maun<br>start is 3<br>lat is -18.55 lon is 25.63 and the city is Pandamatenga<br>start is 4<br>lat is -20.52 lon is 26.10 and the city is Sua_Pan<br>start is 5<br>lat is -21.42 lon is 25.62 and the city is Letlhakane<br>start is 6<br>lat is -21.17 lon is 27.52 and the city is Francistown<br>start is 7<br>lat is -21.97 lon is 27.83 and the city is Selibe_Phikwe<br>start is 8<br>lat is -23.12 lon is 26.83 and the city is Mahalapye<br>start is 9<br>lat is -24.67 lon is 25.92 and the city is
 SSKA<br>start is 10<br>lat is -24.58 lon is 24.80 and the city is Jwaneng<br>start is 11<br>lat is -25.47 lon is 25.43 and the city is Good_Hope<br>start is 12<br>lat is -26.22 lon is 22.40 and the city is Tsabong<br>start is 13<br>lat is -24.02 lon is 21.88 and the city is Tshane<br>start is 14<br>lat is -25.27 lon is 23.25 and the city is Werda<br>start is 15<br>lat is -21.68 lon is 21.63 and the city is Gantsi<br>start is 16<br>lat is -22.38 lon is 26.72 and the city is Serowe<br>start is 17<br>lat is -24.38 lon is 25.50 and the city is Molepolole<br>start is 18<br>lat is -25.75 lon is 28.20 and the city is Pretoria<br>start is 19<br>lat is -33.92 lon is 18.45 and the city is Cape_Town<br>start is 20<br>lat is -22.57 lon is 17.10 and the city is Windhoek<br>start is 21<br>lat is -17.83 lon is 31.05 and the city is Harare<br>start is 22<br>lat is -29.32 lon is 27.48 and the city is Maseru<br>start is 23<br>lat is -26.33 lon is 31.13 and the city is
 Manzini<br>start is 24<br>lat is -25.97 lon is 32.58 and the city is Maputo<br>start is 25<br>last city is 24<br>No scaling environment<br><br>This means x is environment and y is<br>DRAW error: Syntax is DRAW MARK marktype x y size<br>Non-numeric args to numeric operation<br>&nbsp;  Error occurred on line 53<br>&nbsp;  In file city_plot.gs<br><br><br>-- <br>Muhammad Rahiz<br>Researcher &amp; DPhil Candidate (Climate Systems &amp; Policy)<br>School of Geography &amp; the Environment<br>University of Oxford<br><br>On Tue, 8 Feb 2011, Galebonwe Ramaphane wrote:<br><br>&gt; Muhammad,<br>&gt;<br>&gt; I'm also running GrADS on linux. I have gone over the code several times. It's one of those annoying problems. I'll attach the sample script and the text file for your inspection.<br>&gt;<br>&gt; Galebonwe Ramaphane<br>&gt; Department of Meteorological Services<br>&gt; P.O. BOX 10100<br>&gt; Gaborone<br>&gt; Botswana<br>&gt; Tel: +267 3612200<br>&gt;
 &nbsp;Mobile: +267 74435261<br>&gt;<br>&gt;<br>&gt; -----Original Message-----<br>&gt; From: <a ymailto="mailto:gradsusr-bounces@gradsusr.org" href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a> [mailto:<a ymailto="mailto:gradsusr-bounces@gradsusr.org" href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a>] On Behalf Of Muhammad Rahiz<br>&gt; Sent: Tuesday, February 08, 2011 10:36 AM<br>&gt; To: GrADS Users Forum<br>&gt; Subject: [BULK] Re: [gradsusr] opening text file data<br>&gt; Importance: Low<br>&gt;<br>&gt; Galebonwe,<br>&gt;<br>&gt; I'm using GrADS on linux and as far as I know, if your text file is in the same directory as your script, you don't have to put in the full path.<br>&gt; I'm not sure if it's different on Windows although I doubt so. I presume you've checked your code?<br>&gt;<br>&gt; Muhammad Rahiz<br>&gt; Researcher &amp; DPhil Candidate (Climate Systems &amp; Policy) School of
 Geography &amp; the Environment University of Oxford<br>&gt;<br>&gt; On Tue, 8 Feb 2011, Galebonwe Ramaphane wrote:<br>&gt;<br>&gt;&gt; I have a similar but minor problem. My calling script does not see the text file. I tried putting the text file in the same directory as the calling script. I still failed to read the text file. Do I include the full path of the text file?<br>&gt;&gt;<br>&gt;&gt; Galebonwe Ramaphane<br>&gt;&gt; Department of Meteorological Services<br>&gt;&gt; P.O. BOX 10100<br>&gt;&gt; Gaborone<br>&gt;&gt; Botswana<br>&gt;&gt; Tel: +267 3612200<br>&gt;&gt; &nbsp;Mobile: +267 74435261<br>&gt;&gt;<br>&gt;&gt; -----Original Message-----<br>&gt;&gt; From: <a ymailto="mailto:gradsusr-bounces@gradsusr.org" href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a><br>&gt;&gt; [mailto:<a ymailto="mailto:gradsusr-bounces@gradsusr.org" href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a>] On Behalf Of
 Muhammad Rahiz<br>&gt;&gt; Sent: Monday, February 07, 2011 6:32 PM<br>&gt;&gt; To: GrADS Users Forum<br>&gt;&gt; Subject: Re: [gradsusr] opening text file data<br>&gt;&gt;<br>&gt;&gt; James, you can try the following.<br>&gt;&gt;<br>&gt;&gt; *****<br>&gt;&gt;<br>&gt;&gt; 'sdfopen ifile.nc'<br>&gt;&gt;<br>&gt;&gt; * ttot = number of lines in text file<br>&gt;&gt; ttot = 755<br>&gt;&gt; tx = 1<br>&gt;&gt; while(tx&lt;=ttot)<br>&gt;&gt; fname ='7hA01.out.txt'<br>&gt;&gt;&nbsp; rec = read(fname)<br>&gt;&gt;&nbsp; IO = sublin(rec,1)<br>&gt;&gt;&nbsp;  if(IO = 1)<br>&gt;&gt;&nbsp; &nbsp; say fname' &gt; File open error'<br>&gt;&gt;&nbsp; &nbsp; 'quit'<br>&gt;&gt;&nbsp;  endif<br>&gt;&gt;&nbsp; if(IO = 0)<br>&gt;&gt;&nbsp; &nbsp; t1 = subwrd(rec,2)<br>&gt;&gt;&nbsp; &nbsp; t2 = subwrd(rec,3)<br>&gt;&gt;&nbsp;  endif<br>&gt;&gt; say ''t1' 't2''<br>&gt;&gt;<br>&gt;&gt; tx = tx +1<br>&gt;&gt; endwhile<br>&gt;&gt;<br>&gt;&gt; *****<br>&gt;&gt;<br>&gt;&gt;
 --<br>&gt;&gt; Muhammad Rahiz<br>&gt;&gt; Researcher &amp; DPhil Candidate (Climate Systems &amp; Policy) School of<br>&gt;&gt; Geography &amp; the Environment University of Oxford<br>&gt;&gt;<br>&gt;&gt; On Mon, 7 Feb 2011, James Ciarlo` wrote:<br>&gt;&gt;<br>&gt;&gt;&gt; Hi,<br>&gt;&gt;&gt; I have several text files such as the one I attached and I need to<br>&gt;&gt;&gt; open them which GrADS but I cannot understand how to do so. Can<br>&gt;&gt;&gt; someone help me please?<br>&gt;&gt;&gt;<br>&gt;&gt;&gt; James<br>&gt;&gt;&gt;<br>&gt;&gt;&gt;<br>&gt;&gt; _______________________________________________<br>&gt;&gt; gradsusr mailing list<br>&gt;&gt; <a ymailto="mailto:gradsusr@gradsusr.org" href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>&gt;&gt; <a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>&gt;&gt;<br>&gt;&gt;
 _______________________________________________<br>&gt;&gt; gradsusr mailing list<br>&gt;&gt; <a ymailto="mailto:gradsusr@gradsusr.org" href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>&gt;&gt; <a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>&gt;&gt;<br>&gt;<br><br></div></div></div><br></body></html>