<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Joshua:<br>
<br>
I think your missing values were changed from -9999 to -9e+08 (or
something very close to that).<br>
You'll need to substitute that number in place of -9999 in your .ctl
file.<br>
<br>
Jim<br>
<br>
<div class="moz-cite-prefix">On 5/27/13 3:26 AM, Qian, JianHua
wrote:<br>
</div>
<blockquote cite="mid:CDC8D729.4870%25jianhua_qian@uml.edu"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<div>Dear grads users,</div>
<div><br>
</div>
<div>I have trouble in using fwrite on a mac os x laptop. I get
the data written from fwrite, but when I plot the data (the
correct values should be between 0 and about 100 mm/day), I got
unrealistic number:</div>
<div>
<div>d pcp</div>
<div>Contouring: -9e+08 to 0 interval 1e+08</div>
</div>
<div><br>
</div>
<div>If I use "options little_endian", the number is of e+38.</div>
<div><br>
</div>
<div>This is how I used the fwrite in a gs file:</div>
<div><br>
</div>
<div>
<div>open
/Users/jianhua_qian/Desktop/IRI/desktopdata/cmorph_indo/cmorph_indo.ctl</div>
<div>set fwrite -sq cmorph_03_13_son_mjo1.dat</div>
<div>%set fwrite -be cmorph_03_13_son_mjo1.dat (I tried –be,
but it does not work either)</div>
<div>set x 1 282</div>
<div>set y 1 301</div>
<div>set z 1</div>
<div>set gxout fwrite</div>
<div> set t 2145</div>
<div> d pcp</div>
<div> set t 2146</div>
<div> d pcp</div>
<div> set t 2147</div>
<div> d pcp</div>
<div> set t 2148</div>
<div> d pcp</div>
</div>
<div>…..</div>
<div><br>
</div>
<div>And my ctl file is as follows:</div>
<div><br>
</div>
<div>
<div>dset ^cmorph_03_13_son_mjo1.dat</div>
<div>title cmorph data 7dec2002to14may2013 mjo plases</div>
<div>options sequential</div>
<div>%options big_endian</div>
<div>undef -9999.</div>
<div>xdef 282 linear 74.875 0.25</div>
<div>ydef 301 linear -40.125 0.25</div>
<div>zdef 1 levels 0</div>
<div>tdef 952 linear 00z07Dec2002 3hr</div>
<div>vars 1</div>
<div>pcp 0 99 mm/hr (00z data represents pcp of 00z to 03z)</div>
</div>
<div><br>
</div>
<div>-----</div>
<div>I tried big_endian, little-endian, sequential, and
biteswapped, but none works.</div>
<div><br>
</div>
<div>Could someone in the grads user group give me a clue?</div>
<div><br>
</div>
<div>Thanks!</div>
<div>Joshua Qian</div>
<div><br>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
gradsusr mailing list
<a class="moz-txt-link-abbreviated" href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>
<a class="moz-txt-link-freetext" href="http://gradsusr.org/mailman/listinfo/gradsusr">http://gradsusr.org/mailman/listinfo/gradsusr</a>
</pre>
</blockquote>
<br>
</body>
</html>