Thanks a lot. Sorry I forgot, the version of GrADS is opengrads. Ok then, I will try the re() function. <br><br><div class="gmail_quote">On Tue, Nov 8, 2011 at 2:01 PM, Arlindo da Silva <span dir="ltr"><<a href="mailto:dasilva@alum.mit.edu">dasilva@alum.mit.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Jessica,<div><br></div><div>GrADS does not perform automatic regridding. If the 2 files have different lat/lon grids you won't be able to subtract them unless you regrid one of the variables. You forgot to tell us the version of GrADS you are running, so I am sure if you are using opengrads or not. If using opengrads you should use the <a href="http://opengrads.org/doc/udxt/re/" target="_blank">re()</a> function with box averaging to remap the higher resolution variable to the grid of the lower resolution.</div>
<div><br></div><div>The COLA releases come with a linear interpolation function <a href="http://grads.iges.org/grads/gadoc/gradfunclterp.html" target="_blank">lterp() </a>that performs bilinear interpolation. Given that your variable is soil temperature, I'd not recommend linear interpolation in this case, but for a quick plot it should be OK.</div>
<div><br></div><div> Arlindo</div><div><br></div><div><br></div><div><div class="gmail_quote"><div><div class="h5">On Mon, Nov 7, 2011 at 12:57 PM, jessica falzon <span dir="ltr"><<a href="mailto:jessica.falzon91@gmail.com" target="_blank">jessica.falzon91@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">Hello. I am Jessica and I really appreciate if you help me solve this problem. <br><br>
I am running GrADS on LINUX<br>
<br>I am trying to do a bias of a measured file (<a href="http://08225.30yr.mean.stat.pp.nc" target="_blank">08225.30yr.mean.stat.pp.nc</a>) and a referenced file (8225_ESRL_1960-1990.nc). The problem is that although I am defining the latitude and longitude, an error occurs stating that the grids do not match.<br>
<br>The red part is the error output of GrADS.<br><div><br></div><span style="color:rgb(0, 0, 153)">ga -> sdfopen 8225_ESRL_1960-1990.nc</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">Scanning self-describing file: 8225_ESRL_190-1990.nc</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">SDF file 8225_ESRL_1960-1990.nc is open as file1</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">LON set to 84.375 165</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">LAT set to -48.5705 21.9044</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">LEV set to 0 0</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">Time values set: 1960:1:1:0 1960:1:1:0</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">E set to 1 1</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">ga -> sdfopen <a href="http://08225.30yr.mean.stat.pp.nc/" target="_blank">08225.30yr.mean.stat.pp.nc</a> is open as file 2</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">ga -> q file1</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">File 1: Monthly NOAA-CIRES 20th century Reanalysis V2</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)"> Descriptor : 8225_ESRL_1960-1990.nc</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)"> Binary: 8225_ESRL_1960-1990.nc</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)"> Type = Gridded</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)"> Xsize=44 Ysize=38 Zsize=1 Tsize=373 Esize=1</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)"> Number of variables = 1</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)"> tsoil 1 t.z.y,x Monthly Soil Temperature</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">ga -> q file2</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">File 2: Descriptor: <a href="http://08225.30yr.mean.stat.pp.nc/" target="_blank">08225.30yr.mean.stat.pp.nc</a></span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)"> Binary: <a href="http://08225.30yr.mean.stat.pp.nc/" target="_blank">08225.30yr.mean.stat.pp.nc</a></span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)"> Type = Gridded</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)"> Xsize=174 Ysize=150 Zsize=1 Tsize=1 Esize=1</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">
Number of variables = 1</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">
soiltemp 1 t.z.y,x Soil Temperature (levels 2,3,4)</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">ga -> set gxout grfill</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">ga -> set lat -48.5705 21.9044</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">LAT set to -48.5705 21.9044</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">ga -> set lon 84.375165</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">LON set to 84.375165</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">ga -> set gxout grfill</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">ga -> run bluewhitered</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">Enter Min,interval,num of intervals, center</span><br style="color:rgb(0, 0, 153)">
<span style="color:rgb(0, 0, 153)">-5 1 12</span><br style="color:rgb(0, 0, 153)"><span style="color:rgb(0, 0, 153)">ga -> d soiltemp.2 - tsoil.1</span><br><font color="#ff0000">Data Request Warning: Request is completely outside file limits<br>
Entire grid contents are set to missing data<br>Grid limits of file: X=1 174 Y-1 150 Z= 1 1 T=1 1 E =1 1<br>Grid limits of request: X = -167 17 Y=-8 153 Z = 0 0 T = -7511039 -7511039 E = 1 1<br>Warning issued for variable = soiltemp. 2<br>
Operation error: Incompatable grids<br>Dimension ranges aren't equivalent<br>Dimension = 0<br>1st grid range = -167 17 2nd = 1 44<br>Error ocurred at column 19<br>Expression = soiltemp.2 - tsoil.1</font><br><div style="padding:0px;margin-left:0px;margin-top:0px;overflow:hidden;word-wrap:break-word;color:black;font-size:10px;text-align:left;line-height:130%">
</div>
<br></div></div><div class="im">_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org" target="_blank">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br></div></blockquote></div><span class="HOEnZb"><font color="#888888"><br><br clear="all"><div><br></div>-- <br>Arlindo da Silva<br><a href="mailto:dasilva@alum.mit.edu" target="_blank">dasilva@alum.mit.edu</a><br>
</font></span></div>
<br>_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br></blockquote></div><br><div style="visibility: hidden; left: -5000px; position: absolute; z-index: 9999; padding: 0px; margin-left: 0px; margin-top: 0px; overflow: hidden; word-wrap: break-word; color: black; font-size: 10px; text-align: left; line-height: 130%;" id="avg_ls_inline_popup">
</div>